modal ajax bug fixing