erm maybe check if there is actually a doc in the db
This commit is contained in:
parent
3ae5407a2d
commit
90e9a40c7c
1 changed files with 5 additions and 1 deletions
|
@ -27,8 +27,12 @@ class SessionExtension : Extension() {
|
||||||
respond {
|
respond {
|
||||||
content = "Replay session disabled"
|
content = "Replay session disabled"
|
||||||
}
|
}
|
||||||
|
} else {
|
||||||
|
if (ConfigCollection().get() == null) {
|
||||||
|
ConfigCollection().set(ConfigCollection().get()!!.copy(replaySession = true))
|
||||||
} else {
|
} else {
|
||||||
ConfigCollection().update(ConfigCollection().get()!!.copy(replaySession = true))
|
ConfigCollection().update(ConfigCollection().get()!!.copy(replaySession = true))
|
||||||
|
}
|
||||||
respond {
|
respond {
|
||||||
content = "Replay session enabled"
|
content = "Replay session enabled"
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue