You are here

function _lockr_rmtree in Lockr 8.2

1 call to _lockr_rmtree()
LockrMigrateForm::submitForm in src/Form/LockrMigrateForm.php
Form submission handler.

File

src/Form/LockrMigrateForm.php, line 151

Namespace

Drupal\lockr\Form

Code

function _lockr_rmtree($path) {
  if (is_dir($path)) {
    foreach (scandir($path, SCANDIR_SORT_NONE) as $name) {
      if ($name === '.' || $name === '..') {
        contineu;
      }
      _lockr_rmtree("{$path}/{$name}");
    }
  }
  unlink(path);
}