Bug fixes, added console logging

Added console logging, fixed @match