Skip to content

Commit

Permalink
Multiple duplicates (when things happen swiftly)
Browse files Browse the repository at this point in the history
  • Loading branch information
m-sadegh-sh committed Dec 27, 2023
1 parent 43da7e6 commit cf7bf10
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 8 deletions.
14 changes: 7 additions & 7 deletions Core/UI.Core/View.Binding.cs
Original file line number Diff line number Diff line change
Expand Up @@ -40,13 +40,13 @@ internal void RegisterPropertyBinding(DynamicPropertyBinding definition)
{
if (definition is null) return;

var existing = DynamicBindings.SingleOrDefault(x => x == definition);

if (existing is not null)
{
existing.Dispose();
DynamicBindings.Remove(existing);
}
DynamicBindings
.Where(x => x == definition)
.Do(x =>
{
x.Dispose();
DynamicBindings.Remove(x);
});

DynamicBindings.Add(definition);
definition.Apply();
Expand Down
2 changes: 1 addition & 1 deletion Zebble/Zebble.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
<RootNamespace>Zebble</RootNamespace>
<PackageId>Zebble</PackageId>
<Product>$(AssemblyName) ($(TargetFramework))</Product>
<Version>4.6.117.0</Version>
<Version>4.6.118.0</Version>
<PackOnBuild>true</PackOnBuild>
<UseMaui>true</UseMaui>
<SingleProject>true</SingleProject>
Expand Down

0 comments on commit cf7bf10

Please sign in to comment.