Skip to content

Commit

Permalink
Merge pull request #31672 from tochev/docs-fix-typo
Browse files Browse the repository at this point in the history
docs: Fix condition example
  • Loading branch information
crw committed Aug 23, 2022
2 parents 22db2e0 + 4e506d5 commit 036db86
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion website/docs/language/expressions/custom-conditions.mdx
Expand Up @@ -242,7 +242,7 @@ Use the [`can` function](/language/functions/can) to concisely use the validity
For example, you can use `can` with `regex` to test if a string matches a particular pattern because `regex` returns an error when given a non-matching string.

```hcl
condition = can(regex("^[a-z]+$", var.name)
condition = can(regex("^[a-z]+$", var.name))
```

You can also use `can` with the type conversion functions to test whether a value is convertible to a type or type constraint.
Expand Down

0 comments on commit 036db86

Please sign in to comment.