Skip to content

Commit c600cbb

Browse files
fix(e2e): patch only public link settings in test helper.
Co-authored-by: Cursor <cursoragent@cursor.com>
1 parent a7bed1c commit c600cbb

1 file changed

Lines changed: 6 additions & 6 deletions

File tree

e2e/helpers/server_api/publicLinks.ts

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -28,13 +28,13 @@ export async function enablePublicLinks(credentials = getTestServerCredentials()
2828
}
2929

3030
const siteURL = config.ServiceSettings?.SiteURL ?? credentials.baseUrl;
31-
await apiRequest(credentials.baseUrl, token, '/api/v4/config', {
31+
const patch: ServerConfig = {
32+
FileSettings: {EnablePublicLink: true},
33+
...(siteURL ? {ServiceSettings: {SiteURL: siteURL}} : {}),
34+
};
35+
await apiRequest(credentials.baseUrl, token, '/api/v4/config/patch', {
3236
method: 'PUT',
33-
body: JSON.stringify({
34-
...config,
35-
ServiceSettings: {...config.ServiceSettings, SiteURL: siteURL},
36-
FileSettings: {...config.FileSettings, EnablePublicLink: true},
37-
}),
37+
body: JSON.stringify(patch),
3838
});
3939

4040
return true;

0 commit comments

Comments
 (0)