Skip to content

Commit

Permalink
Fix small issue
Browse files Browse the repository at this point in the history
  • Loading branch information
orzuionut committed Oct 2, 2019
1 parent 5f0d243 commit 61a361e
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions w2g2/lib/Controller/LockController.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@

namespace OCA\w2g2\Controller;

use Countable;
use OCA\w2g2\UIMessage;
use OCP\IRequest;
use OCP\AppFramework\Http\DataResponse;
Expand Down Expand Up @@ -38,6 +39,10 @@ public function index($files)
{
$files = json_decode($files, true);

if ( ! is_array($files) && ! $files instanceof Countable) {
$files = [];
}

for ($i = 0; $i < count($files); $i++) {
$fileData = [];

Expand Down

0 comments on commit 61a361e

Please sign in to comment.