Fixed clicking on changeset in the list, extracted some utility functions to a separate file.