1
0

refactor: Use ESM (#8358)

* wip

* wip

* fix

* clean up

* Update tsconfig.json

* Update activitypub.ts

* wip
This commit is contained in:
syuilo
2022-02-27 11:07:39 +09:00
committed by GitHub
parent 0a882471f3
commit d071d18dd7
737 changed files with 4135 additions and 3678 deletions
@@ -1,6 +1,5 @@
import autobind from 'autobind-decorator';
import Chart, { KVs } from '../core';
import { name, schema } from './entities/ap-request';
import Chart, { KVs } from '../core.js';
import { name, schema } from './entities/ap-request.js';
/**
* Chart about ActivityPub requests
@@ -11,31 +10,26 @@ export default class ApRequestChart extends Chart<typeof schema> {
super(name, schema);
}
@autobind
protected async tickMajor(): Promise<Partial<KVs<typeof schema>>> {
return {};
}
@autobind
protected async tickMinor(): Promise<Partial<KVs<typeof schema>>> {
return {};
}
@autobind
public async deliverSucc(): Promise<void> {
await this.commit({
'deliverSucceeded': 1,
});
}
@autobind
public async deliverFail(): Promise<void> {
await this.commit({
'deliverFailed': 1,
});
}
@autobind
public async inbox(): Promise<void> {
await this.commit({
'inboxReceived': 1,