You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
* Builds a diagnostic failure message naming the site, the library searched,
574
585
* the path attempted, and the folders that actually exist at that level.
586
+
*
587
+
* `searchedDefaultLibrary` gates the advice about stripping a leading library
588
+
* name: that hint only applies when the path was interpreted against the site's
589
+
* default library, and would be actively misleading when the caller supplied a
590
+
* library name that matched.
575
591
*/
576
592
asyncfunctionbuildFolderNotFoundMessage(
577
593
accessToken: string,
@@ -580,6 +596,7 @@ async function buildFolderNotFoundMessage(
580
596
rawFolderPath: string,
581
597
segments: string[],
582
598
drives: Drive[],
599
+
searchedDefaultLibrary: boolean,
583
600
retryOptions?: RetryOptions
584
601
): Promise<string>{
585
602
constparts=[
@@ -614,9 +631,11 @@ async function buildFolderNotFoundMessage(
614
631
}
615
632
}
616
633
617
-
parts.push(
618
-
'The folder path is relative to the document library root, so a leading "Documents" or "Shared Documents" should be omitted unless a folder by that name really exists.'
619
-
)
634
+
if(searchedDefaultLibrary){
635
+
parts.push(
636
+
'The folder path is relative to the document library root, so a leading "Documents" or "Shared Documents" should be omitted unless a folder by that name really exists.'
0 commit comments