diff --git a/grext/buffer.py b/grext/buffer.py index bf9d8cfcc09627ff0884a6067e4a473d5cc95124..373eba7efbf022398efea258df3fadc1314ef9da 100644 --- a/grext/buffer.py +++ b/grext/buffer.py @@ -26,9 +26,9 @@ class CircularBuffer: """Get the last `m` matrices.""" if m < 0: raise ValueError("`m` should be larger than 0.") - elif m > self.n: + if m > self.n: raise ValueError("`m` should be less than or equal to the buffer `n`.") - elif m > self.count: + if m > self.count: raise ValueError("`m` is larger than the stored matrices.") start_idx = (self.index - m) % self.n