Skip to content

Commit

Permalink
Fix SetEnum function
Browse files Browse the repository at this point in the history
  • Loading branch information
klsruan committed Jul 25, 2023
1 parent 3d70ab3 commit 911740f
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion modules/clipper2/clipper2.moon
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,8 @@ Enums = {

SetEnum = (enumName, n) ->
if type(n) == "string"
assert Enums[enumName][n], "#{enumName} undefined"
n = Enums[enumName][n]
assert n, "#{enumName} undefined"
return n

-- lib
Expand Down

0 comments on commit 911740f

Please sign in to comment.