added button checks for operations