diff options
Diffstat (limited to 'Zotlabs/Update/_1140.php')
-rw-r--r-- | Zotlabs/Update/_1140.php | 27 |
1 files changed, 27 insertions, 0 deletions
diff --git a/Zotlabs/Update/_1140.php b/Zotlabs/Update/_1140.php new file mode 100644 index 000000000..5b4c8f801 --- /dev/null +++ b/Zotlabs/Update/_1140.php @@ -0,0 +1,27 @@ +<?php + +namespace Zotlabs\Update; + +class _1140 { +function run() { + $r = q("select * from clients where true"); + $x = false; + if($r) { + foreach($r as $rr) { + $m = q("INSERT INTO xperm (xp_client, xp_channel, xp_perm) VALUES ('%s', %d, '%s') ", + dbesc($rr['client_id']), + intval($rr['uid']), + dbesc('all') + ); + if(! $m) + $x = true; + } + } + if($x) + return UPDATE_FAILED; + return UPDATE_SUCCESS; +} + + + +}
\ No newline at end of file |