Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

Fix issue when folderpath doesn't start by '/' #542

Merged
merged 1 commit into from
Dec 20, 2021
Merged

Conversation

magarma
Copy link
Contributor

@magarma magarma commented Dec 3, 2021

Fix issue in ClientSidePageContentHelper that happens when a container doesn't start with '/'.
The string.Concat is building the wrong path '{Path_Returned_By_GetContainer}{container}' instead of '{Path_Returned_By_GetContainer}/{container}'.
Using Path combine we avoid that issue
For instance... you can see how that part of the code creates that wrong path {Guid}SiteAssets instead of {Guid}/SiteAssets
image

When container doesn't start with '/' , doing the string.Concat was building the wrong path
'{Path_Returned_By_GetContainer}{container}' instead of '{Path_Returned_By_GetContainer}/{container}'
Using Path combine we avoid that issue
jansenbe added a commit that referenced this pull request Dec 20, 2021
@jansenbe jansenbe merged commit 820f0e0 into pnp:dev Dec 20, 2021
# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants