Browse Source

public fields fix

pull/10860/head
Philipp 7 months ago
parent
commit
cf38b62993
No known key found for this signature in database
GPG Key ID: 24A7501396EB5432
  1. 10
      update.php

10
update.php

@ -55,6 +55,7 @@ use Friendica\Model\Photo;
use Friendica\Model\Post;
use Friendica\Model\Profile;
use Friendica\Model\Storage;
use Friendica\Security\PermissionSet\Depository\PermissionSet;
use Friendica\Worker\Delivery;
// Post-update script of PR 5751
@ -1028,3 +1029,12 @@ function update_1439()
}
DBA::close($intros);
}
function update_1440()
{
// Fix wrong public permissionset
DBA::p("UPDATE `profile_field` SET `psid` = ? WHERE psid IN (SELECT `id` FROM `permissionset` WHERE `id` != ? AND `allow_cid` = '' AND `allow_gid` = '' AND `deny_cid` = '' AND `deny_gid` = '')", PermissionSet::PUBLIC, PermissionSet::PUBLIC);
DBA::delete('permissionset', ["`id` != ? AND `allow_cid` = '' AND `allow_gid` = '' AND `deny_cid` = '' AND `deny_gid` = ''", PermissionSet::PUBLIC]);
return Update::SUCCESS;
}

Loading…
Cancel
Save