ValidColumn reports if the column name is valid (part of the table columns).
(column string)
| 62 | |
| 63 | // ValidColumn reports if the column name is valid (part of the table columns). |
| 64 | func ValidColumn(column string) bool { |
| 65 | for i := range Columns { |
| 66 | if column == Columns[i] { |
| 67 | return true |
| 68 | } |
| 69 | } |
| 70 | return false |
| 71 | } |
| 72 | |
| 73 | var ( |
| 74 | // EmailValidator is a validator for the "email" field. It is called by the builders before save. |
no outgoing calls
no test coverage detected