Skip to content

Commit

Permalink
Fix GTE comparison
Browse files Browse the repository at this point in the history
  • Loading branch information
Atmosfearful committed Oct 29, 2024
1 parent 81448e6 commit bb59dd8
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions app/components/views/PKlima/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -138,16 +138,17 @@ export const PKlima: FC<Props> = (props) => {

const hasApproval = (token: "pklima" | "bct") => {
const value = Number(quantity || "0");
if (token === "pklima")
if (token === "pklima") {
return (
!!exerciseAllowances &&
!!Number(exerciseAllowances.pklima) &&
Number(exerciseAllowances.pklima) > value
Number(exerciseAllowances.pklima) >= value
);
}
return (
!!exerciseAllowances &&
!!Number(exerciseAllowances.bct) &&
Number(exerciseAllowances.bct) > value
Number(exerciseAllowances.bct) >= value
);
};

Expand Down

0 comments on commit bb59dd8

Please sign in to comment.