joomla/joomla-platform — pull request #1762 by elinw (2012-12-17 00:02:27+00:00)
Title: Only attempt to update a session from JUserHelper if there is a session.

If you are creating a user in a cli application updating the current session does not make sense.