fix problem with length 1 values