mirror of
https://git.joinsharkey.org/Sharkey/Sharkey.git
synced 2024-11-30 09:23:09 +02:00
fix(try): ld signature normalizer (#9758)
This commit is contained in:
parent
5b38f76254
commit
00d28826b9
1 changed files with 4 additions and 1 deletions
|
@ -1,5 +1,6 @@
|
||||||
import * as crypto from 'node:crypto';
|
import * as crypto from 'node:crypto';
|
||||||
import { Inject, Injectable } from '@nestjs/common';
|
import { Inject, Injectable } from '@nestjs/common';
|
||||||
|
import jsonld from 'jsonld';
|
||||||
import { HttpRequestService } from '@/core/HttpRequestService.js';
|
import { HttpRequestService } from '@/core/HttpRequestService.js';
|
||||||
import { bindThis } from '@/decorators.js';
|
import { bindThis } from '@/decorators.js';
|
||||||
import { CONTEXTS } from './misc/contexts.js';
|
import { CONTEXTS } from './misc/contexts.js';
|
||||||
|
@ -84,7 +85,9 @@ class LdSignature {
|
||||||
@bindThis
|
@bindThis
|
||||||
public async normalize(data: any) {
|
public async normalize(data: any) {
|
||||||
const customLoader = this.getLoader();
|
const customLoader = this.getLoader();
|
||||||
return 42;
|
return await jsonld.normalize(data, {
|
||||||
|
documentLoader: customLoader,
|
||||||
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
@bindThis
|
@bindThis
|
||||||
|
|
Loading…
Reference in a new issue