.error function added