From 973ef8c4f8c15848dfc135e11053e5eb6f5dcdb7 Mon Sep 17 00:00:00 2001 From: Christian Weiske Date: Fri, 6 Mar 2020 18:33:42 +0100 Subject: Store the hub that was used for Websub subscription --- bin/subscribe.php | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'bin/subscribe.php') diff --git a/bin/subscribe.php b/bin/subscribe.php index 7d05f79..9df5b08 100755 --- a/bin/subscribe.php +++ b/bin/subscribe.php @@ -45,7 +45,7 @@ if ($topic != $url) { $sub = $subDb->get($topic); if ($sub === false) { - $subDb->create($topic); + $subDb->create($topic, $hub); } else { Log::info( 'Topic exists already in subscription table with status ' @@ -53,6 +53,7 @@ if ($sub === false) { ); Log::info('Renewing subscription...'); $subDb->renew($sub->sub_id); + $hub = $sub->sub_hub; } $sub = $subDb->get($topic); -- cgit v1.2.3