bla
This commit is contained in:
parent
655d44e918
commit
b5244c8fa6
1 changed files with 2 additions and 2 deletions
4
index.js
4
index.js
|
@ -462,8 +462,8 @@ fastify.post('/sendTreasure', async (request, reply) => {
|
|||
if ("treasureUid" in content) {
|
||||
let treasureExists = check(content, "activityUid", ActivityData)
|
||||
if (treasureExists.success) {
|
||||
if (treasureData[treasureUid].state != "Pending"
|
||||
&& treasureData[treasureUid].creator == content.uid) {
|
||||
if (TreasureData[treasureUid].state != "Pending"
|
||||
|| TreasureData[treasureUid].creator != content.uid) {
|
||||
return {
|
||||
success: false,
|
||||
why: "You cannot edit already accepted or refused treasure request, or request form other people"
|
||||
|
|
Loading…
Reference in a new issue