Skip to content

Commit

Permalink
Fix undefined
Browse files Browse the repository at this point in the history
  • Loading branch information
w3bdesign committed Mar 2, 2021
1 parent 66d1124 commit 112469c
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion utils/functions/functions.js
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ export const getFloatVal = (string) => {
export const getFormattedCart = (data) => {
let formattedCart = null;

if (undefined === data || !data.cart.contents.nodes.length) {
if (!data || !data.cart.contents.nodes.length) {
return formattedCart;
}

Expand Down

0 comments on commit 112469c

Please sign in to comment.