Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

doc: fix typo #1042

Merged
merged 1 commit into from
Sep 22, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions action.go
Original file line number Diff line number Diff line change
Expand Up @@ -453,7 +453,7 @@ func (a Action) UniqueListF(divider string, f func(s string) string) Action {
})
}

// Unless skips invokation if given condition is true.
// Unless skips invocation if given condition is true.
func (a Action) Unless(condition bool) Action {
return ActionCallback(func(c Context) Action {
if condition {
Expand All @@ -463,7 +463,7 @@ func (a Action) Unless(condition bool) Action {
})
}

// UnlessF skips invokation if given condition returns true.
// UnlessF skips invocation if given condition returns true.
func (a Action) UnlessF(condition func(c Context) bool) Action {
return ActionCallback(func(c Context) Action {
if condition(c) {
Expand Down
2 changes: 1 addition & 1 deletion docs/src/carapace/action/unless.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# Unless

[`Unless`] skips invokation if given condition is `true`.
[`Unless`] skips invocation if given condition is `true`.

```go
carapace.ActionMultiPartsN(":", 2, func(c carapace.Context) carapace.Action {
Expand Down
2 changes: 1 addition & 1 deletion docs/src/carapace/action/unlessF.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# UnlessF

[`UnlessF`] skips invokation if given [condition] returns `true`.
[`UnlessF`] skips invocation if given [condition] returns `true`.

```go
carapace.ActionValues(
Expand Down