You will need to cast $selected variable (around line 219) on the restore or you may get an empty character which makes the file name incorrect.
$file = new File($this->folder . $config . DS . $selected . '' . $versions[(int)$selected]['file']);
to
$file = new File($this->folder . $config . DS . (int) $selected . '' . $versions[(int)$selected]['file']);