Skip to content

Commit

Permalink
fix: event key #2760
Browse files Browse the repository at this point in the history
  • Loading branch information
overtrue committed Nov 30, 2023
1 parent 82dc365 commit 9f933f2
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 3 deletions.
1 change: 1 addition & 0 deletions src/Kernel/Traits/InteractWithHttpClient.php
Expand Up @@ -10,6 +10,7 @@
use Symfony\Component\HttpClient\HttpClient;
use Symfony\Component\HttpClient\ScopingHttpClient;
use Symfony\Contracts\HttpClient\HttpClientInterface;

use function property_exists;

trait InteractWithHttpClient
Expand Down
6 changes: 3 additions & 3 deletions src/Work/Server.php
Expand Up @@ -148,7 +148,7 @@ public function handleUserDeleted(callable $handler): static
public function handlePartyCreated(callable $handler): static
{
$this->with(function (Message $message, Closure $next) use ($handler): mixed {
return $message->InfoType === 'change_contact' && $message->ChangeType === 'create_party' ? $handler(
return $message->Event === 'change_contact' && $message->ChangeType === 'create_party' ? $handler(
$message,
$next
) : $next($message);
Expand All @@ -163,7 +163,7 @@ public function handlePartyCreated(callable $handler): static
public function handlePartyUpdated(callable $handler): static
{
$this->with(function (Message $message, Closure $next) use ($handler): mixed {
return $message->InfoType === 'change_contact' && $message->ChangeType === 'update_party' ? $handler(
return $message->Event === 'change_contact' && $message->ChangeType === 'update_party' ? $handler(
$message,
$next
) : $next($message);
Expand All @@ -178,7 +178,7 @@ public function handlePartyUpdated(callable $handler): static
public function handlePartyDeleted(callable $handler): static
{
$this->with(function (Message $message, Closure $next) use ($handler): mixed {
return $message->InfoType === 'change_contact' && $message->ChangeType === 'delete_party' ? $handler(
return $message->Event === 'change_contact' && $message->ChangeType === 'delete_party' ? $handler(
$message,
$next
) : $next($message);
Expand Down

1 comment on commit 9f933f2

@vercel
Copy link

@vercel vercel bot commented on 9f933f2 Nov 30, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Successfully deployed to the following URLs:

easywechat – ./

easywechat-overtrue.vercel.app
easywechat.vercel.app
easywechat-git-6x-overtrue.vercel.app

Please sign in to comment.