@clairejs/server 3.17.2 → 3.17.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +1 -1
- package/dist/http/utils.js +2 -3
- package/package.json +1 -1
package/README.md
CHANGED
package/dist/http/utils.js
CHANGED
|
@@ -1,7 +1,6 @@
|
|
|
1
|
-
import { getServiceProvider
|
|
1
|
+
import { getServiceProvider } from "@clairejs/core";
|
|
2
2
|
import { AbstractHttpRequestHandler } from "./controller/AbstractHttpRequestHandler";
|
|
3
3
|
import { AbstractServerSocketManager } from "../socket/AbstractServerSocketManager";
|
|
4
|
-
const fields = (getObjectMetadata(ApiInfo)?.fields || []).map((f) => f.name);
|
|
5
4
|
export const getApiInfo = async () => {
|
|
6
5
|
const injector = getServiceProvider().getInjector();
|
|
7
6
|
const httpHandler = injector.resolveOptional(AbstractHttpRequestHandler);
|
|
@@ -10,6 +9,6 @@ export const getApiInfo = async () => {
|
|
|
10
9
|
const httpInfo = httpHandler ? await httpHandler.getMountedEndpointInfo() : [];
|
|
11
10
|
const socketInfo = socketManager ? await socketManager.getMountedEndpointInfo() : [];
|
|
12
11
|
return {
|
|
13
|
-
apis: [...httpInfo, ...socketInfo]
|
|
12
|
+
apis: [...httpInfo, ...socketInfo],
|
|
14
13
|
};
|
|
15
14
|
};
|