Skip to content

Commit

Permalink
Throw error when SP URL is null. Closes pnp#6012
Browse files Browse the repository at this point in the history
  • Loading branch information
Saurabh7019 committed May 15, 2024
1 parent bd3bb30 commit a3fc44b
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/utils/validation.ts
Original file line number Diff line number Diff line change
Expand Up @@ -352,8 +352,8 @@ export const validation = {
},

isValidSharePointUrl(url: string): boolean | string {
if (!url) {
return false;
if (typeof url !== 'string') {
return 'URL must be a string';
}

if (url.indexOf('https://') !== 0) {
Expand Down

0 comments on commit a3fc44b

Please sign in to comment.