+ try {
+ $r->loadById(substr($oneDir, 0, -4));
+ } catch (\VersionControl_Git_Exception $e) {
+ if (strpos($e->getMessage(), 'does not have any commits') !== false) {
+ //the git repo is broken as the initial commit
+ // has not been finished
+ continue;
+ }
+ throw $e;
+ }