Adding hasError method (#45)
This commit is contained in:
parent
271fdd9bde
commit
7aace27355
1 changed files with 2 additions and 0 deletions
|
|
@ -8,6 +8,8 @@ var
|
|||
|
||||
proc hasErrors*(): bool = gerrorCounter != 0
|
||||
|
||||
proc hasError*(field: cstring): bool = gerrorMsgs.contains(field) and len(gerrorMsgs[field]) > 0
|
||||
|
||||
proc disableOnError*(): cstring = toDisabled(hasErrors())
|
||||
|
||||
proc getError*(field: cstring): cstring =
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue