Fixes to rule rendering