cleanup addPrefix check