update and added few functionality