Added sleep to Vault while loop
This commit is contained in:
parent
e370e1f54e
commit
c49a92ecc6
8
vendors/shells/vault.php
vendored
8
vendors/shells/vault.php
vendored
|
|
@ -27,7 +27,7 @@ class VaultShell extends Shell {
|
|||
/******************************************************
|
||||
* Config Variables
|
||||
* *****************************************************/
|
||||
$testing = 0; //Whether to actually move the emails. 1=test, 0=production
|
||||
$testing = 1; //Whether to actually move the emails. 1=test, 0=production
|
||||
|
||||
|
||||
if($testing == 1) {
|
||||
|
|
@ -50,6 +50,12 @@ class VaultShell extends Shell {
|
|||
$processed = scandir($processed_dir);
|
||||
$new = array_diff($emails, $processed);
|
||||
|
||||
if(count($new) == 0) {
|
||||
echo "\rWaiting for new messages";
|
||||
sleep(60);
|
||||
continue;
|
||||
}
|
||||
|
||||
|
||||
|
||||
/* Find the strings we want to look for in the subjects. Build arrays
|
||||
|
|
|
|||
Loading…
Reference in a new issue