I consider that to be a bug.
There is no reason why an inventory should be deleted just because you moved it.
And it makes it annoying to move around storages with valuable items, because you need to drain them to another storage (that you need to buy an excess of) just to be able to safely move the original storage.
It is just super inconvenient.