Added methods conditional for delete and add action.