I think you could look at many repair type installations and find as many violations as you would like. If the box is grounded I dont really see a problem with this. ( Tough to see clearly) Hey Elady are you joking? Forgive me if you are but you are not required to have a 1/8 gap around the box, you may have up to that size gap if not installed in combustible materials.