Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- function topic_needs_resubscribing($hub_topic)
- {
- $pdo = getPdo();
- $query = $pdo->prepare("SELECT `expires_at` < ? as `expired` FROM `subscriptions` WHERE `hub_topic` = ? ORDER BY `expires_at` DESC LIMIT 1");
- $query->execute([
- time(),
- $hub_topic
- ]);
- return (int) $query->fetchColumn(0) === 1;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement