feat: upgrade script to re-assert all known actors to save URL into hash, and bump mentions

This commit is contained in:
Julian Lam
2024-04-04 12:12:15 -04:00
parent 0b2faf21f9
commit 943cef6da2
2 changed files with 19 additions and 1 deletions

View File

@@ -0,0 +1,18 @@
// REMOVE THIS PRIOR TO 4.0 ALPHA
'use strict';
// eslint-disable-next-line no-unused-vars
const db = require('../../database');
const activitypub = require('../../activitypub');
module.exports = {
name: 'Re-assert all existing actors to save URL into hash',
timestamp: Date.UTC(2024, 3, 4),
method: async () => {
const batch = require('../../batch');
const { progress } = this;
await batch.processSortedSet('usersRemote:lastCrawled', async ids => await activitypub.actors.assert(ids, { update: true }), { progress });
},
};