trim value in case of parse fail