some performance and other tweaks
fix bug in recent mod
fix the fix