Perfectly Matched Layers for 3D Time Harmonic Maxwell's equations


I am trying to simulate light scattering off of a nanoparticle, but I strongly suspect that I am using the PML incorrectly. Whenever I comment out the line that sets the PML (line 87), nothing happens. in the file that I’ve attached, I have a basic example where I am integrating the calculated electric field in the region that is supposed to the PML. You can see for yourself that the value when the PML is set is the same as when the PML is not set. I was wondering if someone could point out what I’m doing wrong?

Thank you very much for your time