adding error logging functionality