mirror of
https://github.com/multipleof4/ntfy.git
synced 2026-10-13 07:15:19 +00:00
Start work on ephemeral topics
This commit is contained in:
@@ -25,13 +25,7 @@ const SubscribeDialog = (props) => {
|
||||
const fullScreen = useMediaQuery(theme.breakpoints.down('sm'));
|
||||
const handleSuccess = async () => {
|
||||
const actualBaseUrl = (baseUrl) ? baseUrl : window.location.origin;
|
||||
const subscription = {
|
||||
id: topicUrl(actualBaseUrl, topic),
|
||||
baseUrl: actualBaseUrl,
|
||||
topic: topic,
|
||||
last: null
|
||||
};
|
||||
await subscriptionManager.save(subscription);
|
||||
const subscription = await subscriptionManager.add(actualBaseUrl, topic, false);
|
||||
poller.pollInBackground(subscription); // Dangle!
|
||||
props.onSuccess(subscription);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user