Skip to content

Commit

Permalink
fix: issue of registered listener is not being remove on RemoveListen…
Browse files Browse the repository at this point in the history
…er. (#227)

* fix: issue of registered listener is not being remove on RemoveListener.

* PubNub SDK v6.20.2.0 release.

---------

Co-authored-by: PubNub Release Bot <[email protected]>
  • Loading branch information
mohitpubnub and pubnub-release-bot authored Oct 3, 2024
1 parent f352181 commit 43494fd
Show file tree
Hide file tree
Showing 9 changed files with 39 additions and 27 deletions.
4 changes: 2 additions & 2 deletions .github/CODEOWNERS
Validating CODEOWNERS rules …
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
* @mohitpubnub @xavrax @marcin-cebo
README.md @techwritermat @kazydek @mohitpubnub @xavrax
* @mohitpubnub @xavrax @marcin-cebo @jakub-grzesiowski
README.md @techwritermat @kazydek @mohitpubnub @xavrax @jakub-grzesiowski
19 changes: 12 additions & 7 deletions .pubnub.yml
Original file line number Diff line number Diff line change
@@ -1,8 +1,13 @@
name: c-sharp
version: "6.20.1"
version: "6.20.2"
schema: 1
scm: github.com/pubnub/c-sharp
changelog:
- date: 2024-10-03
version: v6.20.2
changes:
- type: bug
text: "Fixes issue of listener not being removed on RemoveListener call."
- date: 2024-05-09
version: v6.20.1
changes:
Expand Down Expand Up @@ -788,7 +793,7 @@ features:
- QUERY-PARAM
supported-platforms:
-
version: Pubnub 'C#' 6.20.1
version: Pubnub 'C#' 6.20.2
platforms:
- Windows 10 and up
- Windows Server 2008 and up
Expand All @@ -799,7 +804,7 @@ supported-platforms:
- .Net Framework 4.6.1+
- .Net Framework 6.0
-
version: PubnubPCL 'C#' 6.20.1
version: PubnubPCL 'C#' 6.20.2
platforms:
- Xamarin.Android
- Xamarin.iOS
Expand All @@ -819,7 +824,7 @@ supported-platforms:
- .Net Core
- .Net 6.0
-
version: PubnubUWP 'C#' 6.20.1
version: PubnubUWP 'C#' 6.20.2
platforms:
- Windows Phone 10
- Universal Windows Apps
Expand All @@ -843,7 +848,7 @@ sdks:
distribution-type: source
distribution-repository: GitHub
package-name: Pubnub
location: https://github.com/pubnub/c-sharp/releases/tag/v6.20.1.0
location: https://github.com/pubnub/c-sharp/releases/tag/v6.20.2.0
requires:
-
name: ".Net"
Expand Down Expand Up @@ -1126,7 +1131,7 @@ sdks:
distribution-type: source
distribution-repository: GitHub
package-name: PubNubPCL
location: https://github.com/pubnub/c-sharp/releases/tag/v6.20.1.0
location: https://github.com/pubnub/c-sharp/releases/tag/v6.20.2.0
requires:
-
name: ".Net Core"
Expand Down Expand Up @@ -1485,7 +1490,7 @@ sdks:
distribution-type: source
distribution-repository: GitHub
package-name: PubnubUWP
location: https://github.com/pubnub/c-sharp/releases/tag/v6.20.1.0
location: https://github.com/pubnub/c-sharp/releases/tag/v6.20.2.0
requires:
-
name: "Universal Windows Platform Development"
Expand Down
4 changes: 4 additions & 0 deletions CHANGELOG
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
v6.20.2 - October 03 2024
-----------------------------
- Fixed: fixes issue of listener not being removed on RemoveListener call.

v6.20.1 - May 09 2024
-----------------------------
- Fixed: fixes issue of Unity SDK not being able to have a fully independent IJsonPluggableLibrary implementation because of direct nu-get Newtonsoft usage in C# SDK (Unity has it's own version that works with IL2CPP builds).
Expand Down
4 changes: 2 additions & 2 deletions src/Api/PubnubApi/Properties/AssemblyInfo.cs
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,8 @@
[assembly: AssemblyProduct("Pubnub C# SDK")]
[assembly: AssemblyCopyright("Copyright © 2021")]
[assembly: AssemblyTrademark("")]
[assembly: AssemblyVersion("6.20.1.0")]
[assembly: AssemblyFileVersion("6.20.1.0")]
[assembly: AssemblyVersion("6.20.2.0")]
[assembly: AssemblyFileVersion("6.20.2.0")]
// Setting ComVisible to false makes the types in this assembly not visible
// to COM components. If you need to access a type in this assembly from
// COM, set the ComVisible attribute to true on that type.
Expand Down
21 changes: 12 additions & 9 deletions src/Api/PubnubApi/Pubnub.cs
Original file line number Diff line number Diff line change
Expand Up @@ -412,15 +412,18 @@ public bool AddListener(SubscribeCallback listener)
}
}

public bool RemoveListener(SubscribeCallback listener)
{
bool ret = false;
if (subscribeCallbackListenerList != null)
{
ret = subscribeCallbackListenerList.Remove(listener);
}
return ret;
}
public bool RemoveListener(SubscribeCallback listener)
{
bool ret = false;
if (subscribeCallbackListenerList != null) {
ret = subscribeCallbackListenerList.Remove(listener);
}
if (listenerManager != null) {
var removeFromListenerManager = listenerManager.RemoveListener(listener);
if (!ret) ret = ret || removeFromListenerManager;
}
return ret;
}
#endregion

public EndPoint.SendFileOperation SendFile()
Expand Down
4 changes: 2 additions & 2 deletions src/Api/PubnubApi/PubnubApi.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -14,15 +14,15 @@

<PropertyGroup>
<PackageId>Pubnub</PackageId>
<PackageVersion>6.20.1.0</PackageVersion>
<PackageVersion>6.20.2.0</PackageVersion>
<Title>PubNub C# .NET - Web Data Push API</Title>
<Authors>Pandu Masabathula</Authors>
<Owners>PubNub</Owners>
<PackageLicenseFile>LICENSE.txt</PackageLicenseFile>
<PackageIconUrl>http://pubnub.s3.amazonaws.com/2011/powered-by-pubnub/pubnub-icon-600x600.png</PackageIconUrl>
<PackageRequireLicenseAcceptance>true</PackageRequireLicenseAcceptance>
<RepositoryUrl>https://github.com/pubnub/c-sharp/</RepositoryUrl>
<PackageReleaseNotes>Fixes issue of Unity SDK not being able to have a fully independent IJsonPluggableLibrary implementation because of direct nu-get Newtonsoft usage in C# SDK (Unity has it's own version that works with IL2CPP builds).</PackageReleaseNotes>
<PackageReleaseNotes>Fixes issue of listener not being removed on RemoveListener call.</PackageReleaseNotes>
<PackageTags>Web Data Push Real-time Notifications ESB Message Broadcasting Distributed Computing</PackageTags>
<!--<Summary>PubNub is a Massively Scalable Web Push Service for Web and Mobile Games. This is a cloud-based service for broadcasting messages to thousands of web and mobile clients simultaneously</Summary>-->
<Description>PubNub is a Massively Scalable Web Push Service for Web and Mobile Games. This is a cloud-based service for broadcasting messages to thousands of web and mobile clients simultaneously</Description>
Expand Down
4 changes: 2 additions & 2 deletions src/Api/PubnubApiPCL/PubnubApiPCL.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -15,15 +15,15 @@

<PropertyGroup>
<PackageId>PubnubPCL</PackageId>
<PackageVersion>6.20.1.0</PackageVersion>
<PackageVersion>6.20.2.0</PackageVersion>
<Title>PubNub C# .NET - Web Data Push API</Title>
<Authors>Pandu Masabathula</Authors>
<Owners>PubNub</Owners>
<PackageLicenseFile>LICENSE.txt</PackageLicenseFile>
<PackageIconUrl>http://pubnub.s3.amazonaws.com/2011/powered-by-pubnub/pubnub-icon-600x600.png</PackageIconUrl>
<PackageRequireLicenseAcceptance>true</PackageRequireLicenseAcceptance>
<RepositoryUrl>https://github.com/pubnub/c-sharp/</RepositoryUrl>
<PackageReleaseNotes>Fixes issue of Unity SDK not being able to have a fully independent IJsonPluggableLibrary implementation because of direct nu-get Newtonsoft usage in C# SDK (Unity has it's own version that works with IL2CPP builds).</PackageReleaseNotes>
<PackageReleaseNotes>Fixes issue of listener not being removed on RemoveListener call.</PackageReleaseNotes>
<PackageTags>Web Data Push Real-time Notifications ESB Message Broadcasting Distributed Computing</PackageTags>
<!--<Summary>PubNub is a Massively Scalable Web Push Service for Web and Mobile Games. This is a cloud-based service for broadcasting messages to thousands of web and mobile clients simultaneously</Summary>-->
<Description>PubNub is a Massively Scalable Web Push Service for Web and Mobile Games. This is a cloud-based service for broadcasting messages to thousands of web and mobile clients simultaneously</Description>
Expand Down
4 changes: 2 additions & 2 deletions src/Api/PubnubApiUWP/PubnubApiUWP.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -16,15 +16,15 @@

<PropertyGroup>
<PackageId>PubnubUWP</PackageId>
<PackageVersion>6.20.1.0</PackageVersion>
<PackageVersion>6.20.2.0</PackageVersion>
<Title>PubNub C# .NET - Web Data Push API</Title>
<Authors>Pandu Masabathula</Authors>
<Owners>PubNub</Owners>
<PackageLicenseFile>LICENSE.txt</PackageLicenseFile>
<PackageIconUrl>http://pubnub.s3.amazonaws.com/2011/powered-by-pubnub/pubnub-icon-600x600.png</PackageIconUrl>
<PackageRequireLicenseAcceptance>true</PackageRequireLicenseAcceptance>
<RepositoryUrl>https://github.com/pubnub/c-sharp/</RepositoryUrl>
<PackageReleaseNotes>Fixes issue of Unity SDK not being able to have a fully independent IJsonPluggableLibrary implementation because of direct nu-get Newtonsoft usage in C# SDK (Unity has it's own version that works with IL2CPP builds).</PackageReleaseNotes>
<PackageReleaseNotes>Fixes issue of listener not being removed on RemoveListener call.</PackageReleaseNotes>
<PackageTags>Web Data Push Real-time Notifications ESB Message Broadcasting Distributed Computing</PackageTags>
<!--<Summary>PubNub is a Massively Scalable Web Push Service for Web and Mobile Games. This is a cloud-based service for broadcasting messages to thousands of web and mobile clients simultaneously</Summary>-->
<Description>PubNub is a Massively Scalable Web Push Service for Web and Mobile Games. This is a cloud-based service for broadcasting messages to thousands of web and mobile clients simultaneously</Description>
Expand Down
2 changes: 1 addition & 1 deletion src/Api/PubnubApiUnity/PubnubApiUnity.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@

<PropertyGroup>
<PackageId>PubnubApiUnity</PackageId>
<PackageVersion>6.20.1.0</PackageVersion>
<PackageVersion>6.20.2.0</PackageVersion>
<Title>PubNub C# .NET - Web Data Push API</Title>
<Authors>Pandu Masabathula</Authors>
<Owners>PubNub</Owners>
Expand Down

0 comments on commit 43494fd

Please sign in to comment.