do not check repository unless it is non-null in getHistory()