1
0
mirror of https://github.com/ascribe/onion.git synced 2024-12-23 01:39:36 +01:00
onion/js/actions/license_actions.js
2015-10-06 16:47:59 +02:00

26 lines
525 B
JavaScript

'use strict';
import { alt } from '../alt';
import LicenseFetcher from '../fetchers/license_fetcher';
class LicenseActions {
constructor() {
this.generateActions(
'updateLicenses'
);
}
fetchLicense() {
LicenseFetcher.fetch()
.then((res) => {
this.actions.updateLicenses(res.licenses);
})
.catch((err) => {
console.logGlobal(err);
});
}
}
export default alt.createActions(LicenseActions);