Implement set-command

This commit is contained in:
Shin'ya Ueoka 2018-07-26 21:41:00 +09:00
parent c4afd7237b
commit 86c4841964
5 changed files with 145 additions and 26 deletions

View file

@ -14,4 +14,10 @@ export default class SettingRepository {
update(value) {
return this.cache.set(CACHED_SETTING_KEY, value);
}
async setProperty(name, value) {
let current = await this.get();
current.properties[name] = value;
return this.update(current);
}
}