fix js so .gif is removed on correct modal click