Skip to content

Commit

Permalink
Merge branch 'YvanBrunelOfficialBranch' into v4.0-hotfix
Browse files Browse the repository at this point in the history
  • Loading branch information
YBTopaz8 authored Dec 22, 2024
2 parents 2d3b3f4 + 6346a77 commit d4c8ff1
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 3 deletions.
12 changes: 10 additions & 2 deletions Parse/Platform/Installations/ParseInstallation.cs
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,7 @@ public Guid InstallationId
get
{
string installationIdString = GetProperty<string>(nameof(InstallationId));

if (Guid.TryParse(installationIdString, out Guid installationId))
{
return installationId;
Expand Down Expand Up @@ -97,7 +98,6 @@ public string TimeZone
private set => SetProperty(value, nameof(TimeZone));
}

/// <summary>
/// The users locale. This field gets automatically populated by the SDK.
/// Can be null (Parse Push uses default language in this case).
/// </summary>

Check warning on line 103 in Parse/Platform/Installations/ParseInstallation.cs

View workflow job for this annotation

GitHub Actions / .NET 8.0

XML comment has badly formed XML -- 'End tag was not expected at this location.'

Check warning on line 103 in Parse/Platform/Installations/ParseInstallation.cs

View workflow job for this annotation

GitHub Actions / .NET 7.0

XML comment has badly formed XML -- 'End tag was not expected at this location.'

Check warning on line 103 in Parse/Platform/Installations/ParseInstallation.cs

View workflow job for this annotation

GitHub Actions / .NET 9.0

XML comment has badly formed XML -- 'End tag was not expected at this location.'

Check warning on line 103 in Parse/Platform/Installations/ParseInstallation.cs

View workflow job for this annotation

GitHub Actions / .NET 6.0

XML comment has badly formed XML -- 'End tag was not expected at this location.'

Check warning on line 103 in Parse/Platform/Installations/ParseInstallation.cs

View workflow job for this annotation

GitHub Actions / .NET 6.0

XML comment has badly formed XML -- 'End tag was not expected at this location.'
Expand All @@ -118,6 +118,7 @@ private string GetLocaleIdentifier()
string countryCode = null;

if (CultureInfo.CurrentCulture != null)

{
languageCode = CultureInfo.CurrentCulture.TwoLetterISOLanguageName;
}
Expand Down Expand Up @@ -183,8 +184,10 @@ protected override async Task SaveAsync(Task toAwait, CancellationToken cancella

}


Task platformHookTask = ParseClient.Instance.InstallationDataFinalizer.FinalizeAsync(this);


// Wait for the platform task, then proceed with saving the main task.
try
{
Expand Down Expand Up @@ -218,7 +221,9 @@ protected override async Task SaveAsync(Task toAwait, CancellationToken cancella
["UTC-11"] = "Etc/GMT+11",
["Hawaiian Standard Time"] = "Pacific/Honolulu",
["Alaskan Standard Time"] = "America/Anchorage",

["Pacific Standard Time (Mexico)"] = "America/Tijuana",

["Pacific Standard Time"] = "America/Los_Angeles",
["US Mountain Standard Time"] = "America/Phoenix",
["Mountain Standard Time (Mexico)"] = "America/Chihuahua",
Expand All @@ -240,7 +245,9 @@ protected override async Task SaveAsync(Task toAwait, CancellationToken cancella
["E. South America Standard Time"] = "America/Sao_Paulo",
["Argentina Standard Time"] = "America/Buenos_Aires",
["SA Eastern Standard Time"] = "America/Cayenne",

["Greenland Standard Time"] = "America/Nuuk",

["Montevideo Standard Time"] = "America/Montevideo",
["Bahia Standard Time"] = "America/Bahia",
["UTC-02"] = "Etc/GMT+2",
Expand All @@ -260,7 +267,9 @@ protected override async Task SaveAsync(Task toAwait, CancellationToken cancella
["Middle East Standard Time"] = "Asia/Beirut",
["Egypt Standard Time"] = "Africa/Cairo",
["Syria Standard Time"] = "Asia/Damascus",

["E. Europe Standard Time"] = "Europe/Minsk",

["South Africa Standard Time"] = "Africa/Johannesburg",
["FLE Standard Time"] = "Europe/Kiev",
["Turkey Standard Time"] = "Europe/Istanbul",
Expand Down Expand Up @@ -315,7 +324,6 @@ protected override async Task SaveAsync(Task toAwait, CancellationToken cancella
["Samoa Standard Time"] = "Pacific/Apia"
};


/// <summary>
/// This is a mapping of odd TimeZone offsets to their respective IANA codes across the world.
/// This list was compiled from painstakingly pouring over the information available at
Expand Down
2 changes: 1 addition & 1 deletion Parse/Platform/Objects/ParseObject.cs
Original file line number Diff line number Diff line change
Expand Up @@ -150,7 +150,7 @@ protected ParseObject(IServiceHub serviceHub = default) : this(AutoClassName, se
/// <returns>The instance which was mutated.</returns>
public ParseObject Bind(IServiceHub serviceHub)
{
return (Instance: this, Services = serviceHub).Instance;
return (Instance: this, Services = ParseClient.Instance).Instance;
}

/// <summary>
Expand Down
2 changes: 2 additions & 0 deletions Parse/Platform/Objects/ParseObjectClassController.cs
Original file line number Diff line number Diff line change
Expand Up @@ -91,6 +91,7 @@ public void AddValid(Type type)
Mutex.ExitWriteLock();
}


Mutex.EnterReadLock();
RegisterActions.TryGetValue(className, out Action toPerform);
Mutex.ExitReadLock();
Expand Down Expand Up @@ -143,6 +144,7 @@ public IDictionary<string, string> GetPropertyMappings(string className)
if (info is null)
Classes.TryGetValue(ReservedParseObjectClassName, out info);
Mutex.ExitReadLock();

return info.PropertyMappings;
}

Expand Down

0 comments on commit d4c8ff1

Please sign in to comment.