factorize restore
Signed-off-by: Csaba Kiraly <csaba.kiraly@gmail.com>
This commit is contained in:
parent
82ee2b5189
commit
b5368b4e43
|
@ -437,6 +437,9 @@ class Validator:
|
|||
"""It restores the rows assigned to the validator, that can be repaired."""
|
||||
if self.repairOnTheFly:
|
||||
for id in self.rowIDs:
|
||||
self.restoreRow(id)
|
||||
|
||||
def restoreRow(self, id):
|
||||
rep = self.block.repairRow(id)
|
||||
if (rep.any()):
|
||||
# If operation is based on send queues, segments should
|
||||
|
@ -451,6 +454,9 @@ class Validator:
|
|||
"""It restores the columns assigned to the validator, that can be repaired."""
|
||||
if self.repairOnTheFly:
|
||||
for id in self.columnIDs:
|
||||
self.restoreColumn(id)
|
||||
|
||||
def restoreColumn(self, id):
|
||||
rep = self.block.repairColumn(id)
|
||||
if (rep.any()):
|
||||
# If operation is based on send queues, segments should
|
||||
|
|
Loading…
Reference in New Issue