This repository was archived by the owner on Feb 4, 2025. It is now read-only.

Description
let's consider this rule, looking for values between or equals 0 and 1
const rule = { '<=': [0, { var: 'data' }, 1] };
with data being 0, it works
const zeroInput = { data: 0 };
const zeroArrayInput = { data: [0] };
jsonLogic.apply(rule, zeroInput); // returns true
jsonLogic.apply(rule, zeroArrayInput); // returns true
with data being null, this is wrongly interpreted
const nullInput = { data: null };
jsonLogic.apply(rule, nullInput); // returns true, whereas it should be returning false