Lost files after upgrade, got them back, and don't really know why

/var/discourse and ~/var/discourse are not the same directory.