fix end of value