added log display in case of an error