Fixed bug with falsely registering an error on train callback.