refactor trimming more
tuning
prefix-suffix check
fix prefix-suffix check