Fix for mods counting.
Fix for #4011.