From 4624a03f3b518a15c036c72c6fa026365c457f69 Mon Sep 17 00:00:00 2001 From: Jan Romann Date: Thu, 12 Oct 2023 22:04:00 +0200 Subject: [PATCH] fixup! chore(binding-http): enable eslint/strict-boolean-expressions --- packages/binding-http/src/http-server.ts | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/packages/binding-http/src/http-server.ts b/packages/binding-http/src/http-server.ts index c1730b44d..e2b88f97a 100644 --- a/packages/binding-http/src/http-server.ts +++ b/packages/binding-http/src/http-server.ts @@ -319,7 +319,8 @@ export default class HttpServer implements ProtocolServer { private addUrlRewriteEndpoints(form: TD.Form, forms: Array): void { if (this.urlRewrite != null) { for (const [inUri, toUri] of Object.entries(this.urlRewrite)) { - if (form.href.endsWith(toUri)) { + const endsWithToUri: boolean = form.href.endsWith(toUri); + if (endsWithToUri) { const form2 = structuredClone(form); form2.href = form2.href.substring(0, form.href.lastIndexOf(toUri)) + inUri; forms.push(form2);