improved getValue method
added Util or removed if unnecessary