db update to get rid of bogus activitypub xchans which got created due to a bug in the pubcrawl addon
This commit is contained in:
parent
74d80473df
commit
42093aedcf
26
Zotlabs/Update/_1219.php
Normal file
26
Zotlabs/Update/_1219.php
Normal file
@ -0,0 +1,26 @@
|
||||
<?php
|
||||
|
||||
namespace Zotlabs\Update;
|
||||
|
||||
class _1219 {
|
||||
|
||||
function run() {
|
||||
q("START TRANSACTION");
|
||||
|
||||
$r = q("DELETE FROM xchan WHERE
|
||||
xchan_hash like '%s' AND
|
||||
xchan_network = 'activitypub'",
|
||||
dbesc(z_root()) . '%'
|
||||
);
|
||||
|
||||
if($r) {
|
||||
q("COMMIT");
|
||||
return UPDATE_SUCCESS;
|
||||
}
|
||||
else {
|
||||
q("ROLLBACK");
|
||||
return UPDATE_FAILED;
|
||||
}
|
||||
}
|
||||
|
||||
}
|
Reference in New Issue
Block a user