summaryrefslogtreecommitdiffstats
path: root/files/ajax/scan.php
diff options
context:
space:
mode:
Diffstat (limited to 'files/ajax/scan.php')
-rw-r--r--files/ajax/scan.php6
1 files changed, 5 insertions, 1 deletions
diff --git a/files/ajax/scan.php b/files/ajax/scan.php
index 37ce7ab71f0..f7e75d5f8ba 100644
--- a/files/ajax/scan.php
+++ b/files/ajax/scan.php
@@ -22,6 +22,10 @@ if($force or !OC_FileCache::inCache('')){
exit;
}
}else{
- $eventSource->send('success',false);
+ if(isset($eventSource)){
+ $eventSource->send('success',false);
+ }else{
+ exit;
+ }
}
$eventSource->close(); \ No newline at end of file