[UPDATE] add value functions for error handling