Files
overleaf-cep/services/web/app/src/Features/ThirdPartyDataStore/TpdsQueueManager.mjs
Andrew Rumble c6c62088cc Migrate Features to ES modules
GitOrigin-RevId: 4e9d3176b4b5a5504afc102e569a27d7788864a3
2024-10-17 08:06:08 +00:00

18 lines
410 B
JavaScript

import Settings from '@overleaf/settings'
import OError from '@overleaf/o-error'
import { fetchJson } from '@overleaf/fetch-utils'
async function getQueues(userId) {
try {
return await fetchJson(`${Settings.apis.tpdsworker.url}/queues/${userId}`)
} catch (err) {
throw OError.tag(err, 'failed to query TPDS queues for user', { userId })
}
}
export default {
promises: {
getQueues,
},
}