Fixing the registry