Pugs have a genetic predisposition to a disorder known as Cherry Eye. It is a swelling of your dogs third eyelid. You might try googling "cherry eye" and see if it looks like what you are seeing on your dog. There are surgeries that can be done to correct the problem but I do not think it guarantees the problem will never return but will likely be smaller if it does. I would have your vet take a look at it.