Fixed Bugs in Plot Modal controller