Created
September 20, 2023 12:47
-
-
Save anderseknert/1e85f8dde697a7b19480a32d308ab7b5 to your computer and use it in GitHub Desktop.
Multiple outputs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package play | |
import future.keywords.if | |
import future.keywords.in | |
# Both of the conditions could be true | |
validate_user(user) := "valid" if "admin" in user.roles | |
validate_user(user) := "invalid" if not user.email | |
valid := validate_user(input.user) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment