Adding check for when site isn't in test mode or its not set, #454