Fixed bug in error check if block