SAK-23238 - pres.end being called early


git-svn-id: https://source.sakaiproject.org/svn/portal/branches/portal-2.9.x@120152 66ffb92e-73f9-0310-93c1-f5514f145a0a