refactor: Standardize formatting for alive URL construction in InitJob and Register classes

This commit is contained in:
Nawaz Dhandala
2025-12-24 15:39:26 +00:00
parent 19f8dc8b19
commit 583d86bbc9
2 changed files with 6 additions and 6 deletions

View File

@@ -35,9 +35,9 @@ const InitJob: VoidFunction = (): void => {
logger.debug("AI Agent ID: " + aiAgentId.toString());
const aliveUrl: URL = URL.fromString(
ONEUPTIME_URL.toString(),
).addRoute("/api/ai-agent/alive");
const aliveUrl: URL = URL.fromString(ONEUPTIME_URL.toString()).addRoute(
"/api/ai-agent/alive",
);
const result: HTTPResponse<JSONObject> = await API.post({
url: aliveUrl,

View File

@@ -41,9 +41,9 @@ export default class Register {
return process.exit();
}
const aliveUrl: URL = URL.fromString(
ONEUPTIME_URL.toString(),
).addRoute("/api/ai-agent/alive");
const aliveUrl: URL = URL.fromString(ONEUPTIME_URL.toString()).addRoute(
"/api/ai-agent/alive",
);
logger.debug("Registering AI Agent...");
logger.debug("Sending request to: " + aliveUrl.toString());