Changed buttons to appear only for the necessary action