added cleanup code for ob view modal