Added custom error for InvalidScopeRrror;