We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent ee12ab9 commit 0288992Copy full SHA for 0288992
1 file changed
odml/validation.py
@@ -16,22 +16,22 @@ class ValidationError(object):
16
def __init__(self, obj, msg, rank='error'):
17
self.obj = obj
18
self.msg = msg
19
- self.type = rank
+ self.rank = rank
20
21
@property
22
def is_warning(self):
23
- return self.type == 'warning'
+ return self.rank == 'warning'
24
25
26
def is_error(self):
27
- return self.type == 'error'
+ return self.rank == 'error'
28
29
30
def path(self):
31
return self.obj.get_path()
32
33
def __repr__(self):
34
- return "<ValidationError(%s):%s '%s'>" % (self.type,
+ return "<ValidationError(%s):%s '%s'>" % (self.rank,
35
self.obj,
36
self.msg)
37
0 commit comments