adding const modifier to one function that should have had it.