Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add callbacks to notifications #1

Open
wants to merge 3 commits into
base: master
Choose a base branch
from
Open

Add callbacks to notifications #1

wants to merge 3 commits into from

Conversation

vikeri
Copy link

@vikeri vikeri commented May 20, 2019

No description provided.

@vikeri vikeri requested a review from Looveh May 20, 2019 15:49
@@ -3,8 +3,7 @@
.DS_Store

# Xcode
#
build/
Copy link

Choose a reason for hiding this comment

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

Why remove this? It's a common default build path

@Override
public void invoke(Object... args) {
}
});
mRNPushNotificationHelper.clearNotifications();
Copy link

Choose a reason for hiding this comment

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

Wouldn't it be neat to use a callback here too? I'm imagining something like:

public void cancelAllLocalNotifications(Callback callback) {
  helper.cancelAll(() => {
    helper.clear(() => {
      callback()
    })
  })
}

callback.invoke(errorMsg);
Log.e(LOG_TAG, errorMsg);
} else {
callback.invoke();
Copy link

Choose a reason for hiding this comment

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

Nice!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants