fix(FN-4913): complete Step 9 — resolve quality gate failures
Fusion-Task-Id: FN-4913 Fusion-Task-Lineage: 2fa1fe49-a2a9-405d-833b-cb34d41ef19a
This commit is contained in:
committed by
gsxdsm
parent
e9ef40f6a7
commit
cb184910c7
@@ -10,14 +10,15 @@ import { ApiError, badRequest } from "../api-error.js";
|
||||
import type { ApiRouteRegistrar } from "./types.js";
|
||||
|
||||
function emitSecretsAudit(
|
||||
req: any,
|
||||
req: unknown,
|
||||
ctx: Parameters<ApiRouteRegistrar>[0],
|
||||
type: "secret:sync-pull",
|
||||
target: string,
|
||||
metadata: Record<string, unknown>,
|
||||
): void {
|
||||
if (req.runAuditor?.filesystem) {
|
||||
req.runAuditor.filesystem({ type, target, metadata });
|
||||
const requestWithAuditor = req as { runAuditor?: { filesystem?: (input: { type: string; target: string; metadata?: Record<string, unknown> }) => void } };
|
||||
if (requestWithAuditor.runAuditor?.filesystem) {
|
||||
requestWithAuditor.runAuditor.filesystem({ type, target, metadata });
|
||||
return;
|
||||
}
|
||||
ctx.runtimeLogger.child("secrets-sync").info("Secrets sync audit event", { type, target, ...metadata });
|
||||
|
||||
@@ -11,14 +11,15 @@ import { fetchFromRemoteNode, MISSING_REMOTE_NODE_API_KEY_MESSAGE } from "./regi
|
||||
import type { ApiRouteRegistrar } from "./types.js";
|
||||
|
||||
function emitSecretsAudit(
|
||||
req: any,
|
||||
req: unknown,
|
||||
ctx: Parameters<ApiRouteRegistrar>[0],
|
||||
type: "secret:sync-push" | "secret:sync-pull",
|
||||
target: string,
|
||||
metadata: Record<string, unknown>,
|
||||
): void {
|
||||
if (req.runAuditor?.filesystem) {
|
||||
req.runAuditor.filesystem({ type, target, metadata });
|
||||
const requestWithAuditor = req as { runAuditor?: { filesystem?: (input: { type: string; target: string; metadata?: Record<string, unknown> }) => void } };
|
||||
if (requestWithAuditor.runAuditor?.filesystem) {
|
||||
requestWithAuditor.runAuditor.filesystem({ type, target, metadata });
|
||||
return;
|
||||
}
|
||||
ctx.runtimeLogger.child("secrets-sync").info("Secrets sync audit event", { type, target, ...metadata });
|
||||
|
||||
Reference in New Issue
Block a user