akkoma-fe/src/services/config_fetcher/config_fetcher.service.js
floatingghost db46879a8f Big 'ol set of patches and dep maintenance (#212)
Co-authored-by: FloatingGhost <hannah@coffee-and-dreams.uk>
Reviewed-on: AkkomaGang/pleroma-fe#212
2022-11-15 15:47:32 +00:00

14 lines
357 B
JavaScript

import { promiseInterval } from '../promise_interval/promise_interval.js'
const startFetching = ({ credentials, store }) => {
const boundFetchAndUpdate = () => store.dispatch('getSettingsProfile')
boundFetchAndUpdate()
return promiseInterval(boundFetchAndUpdate, 10 * 60000)
}
const configFetcher = {
startFetching
}
export default configFetcher