diff --git a/node_modules/@ethicdevs/fastify-git-server/dist/helpers/sendStatelessRpc.js b/node_modules/@ethicdevs/fastify-git-server/dist/helpers/sendStatelessRpc.js
index 1ac8e37..b2c37ae 100644
--- a/node_modules/@ethicdevs/fastify-git-server/dist/helpers/sendStatelessRpc.js
+++ b/node_modules/@ethicdevs/fastify-git-server/dist/helpers/sendStatelessRpc.js
@@ -22,32 +22,32 @@ function sendStatelessRpc(_a) {
process.stdout.on("data", function (chunk) { return gitStream.write(chunk); });
process.stdout.once("data", function () {
if (opts.withSideBandMessages === true && opts.onPush != null) {
- var onPushPerfomedAction_1 = false;
+ // var onPushPerfomedAction_1 = false;
var shouldAcceptRequest_1 = false;
var denyReason_1 = null;
var accept = function () {
- onPushPerfomedAction_1 = true;
+ // onPushPerfomedAction_1 = true;
shouldAcceptRequest_1 = true;
logTrace("accept was called.");
};
var deny_1 = function (reason) {
- onPushPerfomedAction_1 = true;
+ // onPushPerfomedAction_1 = true;
shouldAcceptRequest_1 = false;
denyReason_1 = reason;
logTrace("deny was called. reason:", reason);
};
// protect against miss-implemented onPush by automatically denying the
// request in case onPush hook does not reply after 30 seconds.
- var autoDenyTimeoutId_1 = setTimeout(function () {
- if (autoDenyTimeoutId_1 == null) {
- return undefined;
- }
- if (autoDenyTimeoutId_1 != null) {
- clearTimeout(autoDenyTimeoutId_1);
- autoDenyTimeoutId_1 = null;
- }
- return deny_1("onPush did not respond within the allowed ".concat(constants_1.ON_PUSH_TIMEOUT_MS, " seconds."));
- }, constants_1.ON_PUSH_TIMEOUT_MS);
+ // var autoDenyTimeoutId_1 = setTimeout(function () {
+ // if (autoDenyTimeoutId_1 == null) {
+ // return undefined;
+ // }
+ // if (autoDenyTimeoutId_1 != null) {
+ // clearTimeout(autoDenyTimeoutId_1);
+ // autoDenyTimeoutId_1 = null;
+ // }
+ // return deny_1("onPush did not respond within the allowed ".concat(constants_1.ON_PUSH_TIMEOUT_MS, " seconds."));
+ // }, constants_1.ON_PUSH_TIMEOUT_MS);
var received = Buffer.from(receiveBuffer.join(""))
.toString("utf-8")
.split(constants_1.GIT_PACK_SEPARATOR);
@@ -79,11 +79,11 @@ function sendStatelessRpc(_a) {
username: username,
},
});
- clearTimeout(autoDenyTimeoutId_1);
- autoDenyTimeoutId_1 = null;
- if (onPushPerfomedAction_1 === false) {
- accept();
- }
+ // clearTimeout(autoDenyTimeoutId_1);
+ // autoDenyTimeoutId_1 = null;
+ // if (onPushPerfomedAction_1 === false) {
+ // accept();
+ // }
if (shouldAcceptRequest_1 === false && denyReason_1 != null) {
process.kill();
gitStream.end();
diff --git a/node_modules/@ethicdevs/fastify-git-server/src/helpers/sendStatelessRpc.ts b/node_modules/@ethicdevs/fastify-git-server/src/helpers/sendStatelessRpc.ts
index 6682ffb..3b63233 100644
--- a/node_modules/@ethicdevs/fastify-git-server/src/helpers/sendStatelessRpc.ts
+++ b/node_modules/@ethicdevs/fastify-git-server/src/helpers/sendStatelessRpc.ts
@@ -9,7 +9,7 @@ import {
GIT_PACK_REGEXP,
GIT_PACK_SEPARATOR,
GIT_STATELESS_RPC_FLAG,
- ON_PUSH_TIMEOUT_MS,
+ // ON_PUSH_TIMEOUT_MS,
} from "../constants";
import { GitServer } from "../types";
import { GitServerMessage } from "./GitServerMessage";
@@ -51,18 +51,18 @@ export function sendStatelessRpc({
process.stdout.on("data", (chunk) => gitStream.write(chunk));
process.stdout.once("data", () => {
if (opts.withSideBandMessages === true && opts.onPush != null) {
- let onPushPerfomedAction: boolean = false;
+ // let onPushPerfomedAction: boolean = false;
let shouldAcceptRequest: boolean = false;
let denyReason: null | string = null;
const accept = () => {
- onPushPerfomedAction = true;
+ // onPushPerfomedAction = true;
shouldAcceptRequest = true;
logTrace("accept was called.");
};
const deny = (reason: string) => {
- onPushPerfomedAction = true;
+ // onPushPerfomedAction = true;
shouldAcceptRequest = false;
denyReason = reason;
logTrace("deny was called. reason:", reason);
@@ -70,18 +70,18 @@ export function sendStatelessRpc({
// protect against miss-implemented onPush by automatically denying the
// request in case onPush hook does not reply after 30 seconds.
- let autoDenyTimeoutId: null | NodeJS.Timer = setTimeout(() => {
- if (autoDenyTimeoutId == null) {
- return undefined;
- }
- if (autoDenyTimeoutId != null) {
- clearTimeout(autoDenyTimeoutId);
- autoDenyTimeoutId = null;
- }
- return deny(
- `onPush did not respond within the allowed ${ON_PUSH_TIMEOUT_MS} seconds.`,
- );
- }, ON_PUSH_TIMEOUT_MS);
+ // let autoDenyTimeoutId: null | NodeJS.Timer = setTimeout(() => {
+ // if (autoDenyTimeoutId == null) {
+ // return undefined;
+ // }
+ // if (autoDenyTimeoutId != null) {
+ // clearTimeout(autoDenyTimeoutId);
+ // autoDenyTimeoutId = null;
+ // }
+ // return deny(
+ // `onPush did not respond within the allowed ${ON_PUSH_TIMEOUT_MS} seconds.`,
+ // );
+ // }, ON_PUSH_TIMEOUT_MS);
const received = Buffer.from(receiveBuffer.join(""))
.toString("utf-8")
@@ -118,14 +118,14 @@ export function sendStatelessRpc({
},
});
- clearTimeout(autoDenyTimeoutId);
- autoDenyTimeoutId = null;
+ // clearTimeout(autoDenyTimeoutId);
+ // autoDenyTimeoutId = null;
- if (onPushPerfomedAction === false) {
- accept();
- }
+ // if (onPushPerfomedAction === false) {
+ // accept();
+ // }
- if (shouldAcceptRequest === false && denyReason != null) {
+ if (shouldAcceptRequest === false) {
process.kill();
gitStream.end();
return reject(new Error(denyReason));