1
0
mirror of https://github.com/bpatrik/pigallery2.git synced 2025-01-06 03:54:12 +02:00

fixing sharing manager update bug

This commit is contained in:
Patrik J. Braun 2018-02-03 20:50:05 -05:00
parent 6be0d308b7
commit 148a2bb3d2

View File

@ -44,7 +44,11 @@ export class SharingManager implements ISharingManager {
if (sharing.timeStamp < Date.now() - Config.Server.sharing.updateTimeout) {
throw "Sharing is locked, can't update anymore"
}
sharing.password = PasswordHelper.cryptPassword(inSharing.password);
if (inSharing.password == null) {
sharing.password = null;
} else {
sharing.password = PasswordHelper.cryptPassword(inSharing.password);
}
sharing.includeSubfolders = inSharing.includeSubfolders;
sharing.expires = inSharing.expires;