I am not sure if this is a problem with Forge or with Optifine, but Forge doesn't seem to recognise Optifine as a mod. (Tested in versions 25.0.44 and 25.0.48). This is with both Optifine 1.13.2 HD U E5 and E6.