Fix for when $wgTitle is null

Change-Id: I170c71d3b515f44e8a2adf735e3ca78ab1f99b03