Made some fixes to the way replicate folders are handled - reverted back to the original