0
0
mirror of https://github.com/naturalcrit/homebrewery.git synced 2025-12-24 18:32:41 +00:00

Handle missing lock property

This commit is contained in:
G.Ambatte
2024-02-28 16:02:35 +13:00
parent 802da2920b
commit 0d1d3a180d

View File

@@ -54,7 +54,7 @@ const api = {
});
stub = stub?.toObject();
if(stub.lock?.state) {
if(stub?.lock?.state) {
// State 1 : Locked for everything
// State 2 : Edit only
if(stub.lock.state == 1 || (stub.lock.state == 2 && accessType != 'edit'))