diff --git a/src/freedombone-client b/src/freedombone-client index 02a9cbe5..e2ad1baa 100755 --- a/src/freedombone-client +++ b/src/freedombone-client @@ -94,8 +94,8 @@ function refresh_gpg_keys { fi fi sudo cp /etc/crontab ~/temp_crontab - sudo chown "$CURR_USER":"$CURR_GROUP" ~/temp_crontab if [ -f ~/temp_crontab ]; then + sudo chown "$CURR_USER":"$CURR_GROUP" ~/temp_crontab if grep -q 'test' ~/temp_crontab; then if ! grep -q 'gpg --refresh-keys' ~/temp_crontab; then echo "0 */$REFRESH_GPG_KEYS_HOURS * * * $CURR_USER /usr/bin/gpg --refresh-keys > /dev/null" >> ~/temp_crontab