Added error log in label functionality