sorry i didn't explain the idea in much detail. the pancake box is mounted directly to the header over the door then the sheetrock around the box with the nm cable coming thru the box and into the fixture.
because of the narrow width of the fixture the entire pancake box is not sufficiently covered by the fix. that is why i usually put a cover on the pan box. if that makes any sense.
thx., ken m