Fix logging for findPatchScript

Change-Id: I7f81a0db5883ba6c71a50e81ecb681d5af95ad95
diff --git a/TestON/bin/findPatchScript.sh b/TestON/bin/findPatchScript.sh
index f88f528..5bda1fe 100755
--- a/TestON/bin/findPatchScript.sh
+++ b/TestON/bin/findPatchScript.sh
@@ -87,10 +87,10 @@
         fi
 
         cd ~/onos
+        PREVIOUS_COMMIT=$COMMIT
         COMMIT=$(git log -1 --skip $SKIP_COMMIT --pretty=fuller | grep -m1 -Po "(?<=commit\s)\w+")
         echo "New commit to be tested : $COMMIT"
         echo "New commit to be tested : $COMMIT" >> $LOG_FILE
-        PREVIOUS_COMMIT=$COMMIT
         STASH_RESULT=$(git stash)
         git checkout $COMMIT
         if [ "$STASH_RESULT" != "No local changes to save" ]; then