added code for extra protection