Added a print out to console to check how far the code is running.
Fixed a logical error on IF-ELSE statement to run matches.