Modified the code to enable cross-storage