Fix a problem with undefined in afterRender.

@rev kgray@
Merge branch 'goliver/master-pending-afterRender-null'