You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Comparing enums generated from Prisma enums is currently a bit annoying since you can't compare them directly with ==, and matching them indents your code more.
I feel like they should derive PartialEq and Eq.
enumStuff {ONETWOTHREE}
if thing == Stuff::One/* binary operation `==` cannot be applied to type `prisma::Thing` */{// ...}
Without it, the workaround is to use match or convert the values to a string with .to_string() and compare that.
The text was updated successfully, but these errors were encountered:
Comparing enums generated from Prisma enums is currently a bit annoying since you can't compare them directly with
==
, andmatch
ing them indents your code more.I feel like they should derive
PartialEq
andEq
.Without it, the workaround is to use
match
or convert the values to a string with.to_string()
and compare that.The text was updated successfully, but these errors were encountered: