Uploaded image for project: 'AeroGear'
  1. AeroGear
  2. AEROGEAR-5376

AeroDoc: Avoid registration with nil value for device token

    XMLWordPrintable

Details

    • Feature Request
    • Resolution: Won't Do
    • Major
    • 1.2.0
    • 1.2.0
    • None
    • None

    Description

      In AeroDoc we try to stash the token:
      https://github.com/aerogear/aerogear-push-quickstart-ios/blob/master/ProDoctor/ProDoctor/AGAppDelegate.m#L49

      However, when APNs registration fails, this callback is invoked:
      https://github.com/aerogear/aerogear-push-quickstart-ios/blob/master/ProDoctor/ProDoctor/AGAppDelegate.m#L53

      That means there is no stashed token.

      Now after we got a successful login, against the AeroDoc backend, we should check if the token is nil or not, before we "blindly" perform a registration with the UnifiedPush Server:
      https://github.com/aerogear/aerogear-push-quickstart-ios/blob/master/ProDoctor/ProDoctor/Classes/Controllers/AGLoginViewController.m#L138

      => A 'nil' check should be done before execution of that method

      Attachments

        Activity

          People

            Unassigned Unassigned
            mwessend@redhat.com Matthias Wessendorf
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: