DAT-2364 Use the value of city_variable instead of object

* Use the value
* Fix PHP strict warning
* Why, oh why PHP doesn't have static typing? :(
DAT-2364 Single function exit point
DAT-2364 Address CR remark to simplify code
Merge pull request #5731 from Wikia/DAT-2364-r255

DAT-2364 Use the value of city_variable instead of object