Change 'if eq .NoHooks false' -> 'if not .NoHooks'
This commit is contained in:
parent
5ba6769134
commit
b1344befe2
4 changed files with 4 additions and 4 deletions
|
@ -13,7 +13,7 @@ type (
|
|||
// {{$tableNameSingular}}Slice is an alias for a slice of pointers to {{$tableNameSingular}}.
|
||||
// This should generally be used opposed to []{{$tableNameSingular}}.
|
||||
{{$tableNameSingular}}Slice []*{{$tableNameSingular}}
|
||||
{{if eq .NoHooks false -}}
|
||||
{{if not .NoHooks -}}
|
||||
// {{$tableNameSingular}}Hook is the signature for custom {{$tableNameSingular}} hook methods
|
||||
{{$tableNameSingular}}Hook func(boil.Executor, *{{$tableNameSingular}}) error
|
||||
{{- end}}
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
{{- if eq .NoHooks false -}}
|
||||
{{- if not .NoHooks -}}
|
||||
{{- $tableNameSingular := .Table.Name | singular | titleCase -}}
|
||||
{{- $varNameSingular := .Table.Name | singular | camelCase -}}
|
||||
var {{$varNameSingular}}BeforeInsertHooks []{{$tableNameSingular}}Hook
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
{{- if eq .NoHooks false -}}
|
||||
{{- if not .NoHooks -}}
|
||||
{{- $tableNameSingular := .Table.Name | singular | titleCase -}}
|
||||
{{- $tableNamePlural := .Table.Name | plural | titleCase -}}
|
||||
{{- $varNamePlural := .Table.Name | plural | camelCase -}}
|
||||
|
|
|
@ -105,7 +105,7 @@ func TestCount(t *testing.T) {
|
|||
{{- end -}}
|
||||
}
|
||||
|
||||
{{if eq .NoHooks false -}}
|
||||
{{if not .NoHooks -}}
|
||||
func TestHooks(t *testing.T) {
|
||||
{{- range $index, $table := .Tables}}
|
||||
{{- if $table.IsJoinTable -}}
|
||||
|
|
Loading…
Reference in a new issue