[CID-1250669] - Prevent NPE when moving an empty folder

Signed-off-by: Oleg Nenashev <o.v.nenashev@gmail.com>
While at it, could you add result verification? I see the point is not throwing NPE here but in a sense this introduces use case not covered by unittest.