feat(settings.lsl): add delete API opcode
Signed-off-by: zontreck <tarapiccari@gmail.com>
This commit is contained in:
parent
3855157441
commit
37895e05ad
2 changed files with 5 additions and 1 deletions
|
@ -4,4 +4,5 @@ string OP_SETTINGS_WRITE = "settings_write";
|
||||||
string OP_SETTINGS_READ = "settings_read";
|
string OP_SETTINGS_READ = "settings_read";
|
||||||
string OP_SETTINGS_REQUEST = "settings_req";
|
string OP_SETTINGS_REQUEST = "settings_req";
|
||||||
string OP_SETTINGS_RESPONSE = "settings_resp";
|
string OP_SETTINGS_RESPONSE = "settings_resp";
|
||||||
string OP_SETTINGS_RESPONSE = "settings_empty";
|
string OP_SETTINGS_RESPONSE = "settings_empty";
|
||||||
|
string OP_SETTINGS_DELETE = "settings_del";
|
|
@ -11,6 +11,9 @@ default
|
||||||
WriteSetting(llJsonGetValue(sMsg, ["key"]), llJsonGetValue(sMsg, ["value"]));
|
WriteSetting(llJsonGetValue(sMsg, ["key"]), llJsonGetValue(sMsg, ["value"]));
|
||||||
} else if(llJsonGetValue(sMsg, ["op"]) == OP_SETTINGS_READ) {
|
} else if(llJsonGetValue(sMsg, ["op"]) == OP_SETTINGS_READ) {
|
||||||
ReadSetting(llJsonGetValue(sMsg, ["key"]));
|
ReadSetting(llJsonGetValue(sMsg, ["key"]));
|
||||||
|
} else if(llJsonGetValue(sMsg, ["op"]) == OP_SETTINGS_DELETE) {
|
||||||
|
llLinksetDataDelete(llJsonGetValue(sMsg, ["key"]));
|
||||||
|
NoSetting(llJsonGetValue(sMsg, ["key"]));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue