Added support for preloading