Fixing nil error. Logging was useless anyway.