remove some redundant code in the resampler wrapper