mirror of
https://github.com/DeviceFarmer/stf.git
synced 2026-04-18 16:13:24 +02:00
25 lines
437 B
JavaScript
25 lines
437 B
JavaScript
module.exports = function AppStateProvider() {
|
|
var values = {
|
|
config: {
|
|
websocketUrl: ''
|
|
},
|
|
user: {
|
|
settings: {}
|
|
}
|
|
}
|
|
|
|
/* global GLOBAL_APPSTATE:false */
|
|
if (typeof GLOBAL_APPSTATE !== 'undefined') {
|
|
values = angular.extend(values, GLOBAL_APPSTATE)
|
|
}
|
|
|
|
return {
|
|
set: function(constants) {
|
|
angular.extend(values, constants)
|
|
},
|
|
$get: function() {
|
|
return values
|
|
}
|
|
}
|
|
}
|