mirror of
https://github.com/jeffvli/feishin.git
synced 2026-05-07 12:30:12 +02:00
fix Subsonic root folder condition (#1686)
- some older subsonic servers used numeric ids which causes the rootFolderId regex to fail which resulted in the getFolder endpoint to always attempt to fetch the root
This commit is contained in:
@@ -763,7 +763,7 @@ export const SubsonicController: InternalControllerEndpoint = {
|
||||
getFolder: async ({ apiClientProps, context, query }) => {
|
||||
const sortOrder = (query.sortOrder?.toLowerCase() ?? 'asc') as 'asc' | 'desc';
|
||||
|
||||
const isRootFolderId = /^\d+$/.test(query.id);
|
||||
const isRootFolderId = query.id === '0';
|
||||
|
||||
if (isRootFolderId) {
|
||||
const res = await ssApiClient(apiClientProps).getIndexes({
|
||||
|
||||
Reference in New Issue
Block a user