@xeno-js/core 4.1.0 → 4.1.1

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/dist/index.cjs CHANGED
@@ -3155,7 +3155,7 @@ var CsrfMiddleware = class {
3155
3155
  const isStateChanging = ["POST", "PUT", "DELETE", "PATCH"].includes(method);
3156
3156
  if (isStateChanging) {
3157
3157
  const policy = this._getRouteMatcher().checkRoutePolicy(req.path, method);
3158
- if (import_shared85.Guards.isDefined(policy.withCsrf) && policy.withCsrf) return await next();
3158
+ if (import_shared85.Guards.isDefined(policy.withCsrf) && !policy.withCsrf) return await next();
3159
3159
  const { network, tracing, identity } = this._requestContext.getContext() ?? {};
3160
3160
  const headerToken = network?.csrf;
3161
3161
  const cookieToken = network?.csrfCookie;