summaryrefslogtreecommitdiff
path: root/src/tools/refresh-question.ts
blob: ff849aed7faf2e56ca41a6f1475a774dbb0b1c5b (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
import { updateQuestion } from '../remote/activitypub/models/question';

async function main(uri: string): Promise<any> {
	return await updateQuestion(uri);
}

export default () => {
	const args = process.argv.slice(3);
	const uri = args[0];

	main(uri).then(result => {
		console.log(`Done: ${result}`);
		process.exit(0);
	}).catch(e => {
		console.warn(e);
		process.exit(1);
	});
}