Police have shut down a flat that was used for drug dealing after concerns about its proximity to a nursery in Bedford.