Added logic for delete in real time.