diff --git a/cleverpush.php b/cleverpush.php index 08e38e9..f7ee2da 100644 --- a/cleverpush.php +++ b/cleverpush.php @@ -677,8 +677,17 @@ public function create_metabox() public function metabox($post) { - $notification_sent = get_post_meta($post->ID, 'cleverpush_notification_sent', true); - $notification_already_sent = ! empty($notification_sent); + $notification_sent = get_post_meta(get_the_ID(), 'cleverpush_notification_sent', true); + + if ($notification_sent) { + $notification_sent_at = get_post_meta(get_the_ID(), 'cleverpush_notification_sent_at', true); + if (!empty($notification_sent_at) && (time() - $notification_sent_at) < 60) { + ?> + ✅ + - -
✅