function isUnsafe(method) {
      const unsafeMethods = getUnsafeMethods();
      return unsafeMethods.indexOf(method) !== -1;
    }
Checks if a passed method is unsafe
@param {string} method Life cycle method
@returns {boolean} Returns true for unsafe methods, otherwise returns false