Uploaded image for project: 'Titanium SDK/CLI'
  1. Titanium SDK/CLI
  2. TIMOB-26319

iOS: "usernotificationsettings" does not include "types" array on iOS 10 and SDK 7.3.0

    Details

    • Type: Bug
    • Status: Closed
    • Priority: High
    • Resolution: Fixed
    • Affects Version/s: Release 7.3.0
    • Fix Version/s: Release 7.3.1
    • Component/s: iOS
    • Labels:
      None

      Description

      When using iOS 10+ on SDK 7.3.0, the "usernotificationsettings" event does not include the "types" array of granted types anymore. An easy workaround is to use the following code, but ideally it should be 100 % backwards compatible.

      Workaround:

      Ti.App.iOS.NotificationCenter.requestUserNotificationSettings(event => {
          const alertSetting = event.alertSetting;
          const badgeSetting = event.badgeSetting;
          const soundSetting = event.soundSetting;
          
          if (alertSetting === Ti.App.iOS.USER_NOTIFICATION_SETTING_ENABLED) {
              // Alert allowed
          }
      });
      

        Attachments

          Activity

            People

            • Assignee:
              hknoechel Hans Knöchel
              Reporter:
              hknoechel Hans Knöchel
              Reviewer:
              Vijay Singh
              Tester:
              Samir Mohammed
            • Watchers:
              0 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved:

                Backbone Issue Sync

                • Titanium SDK/CLI <> Titanium Mobile
                  Synced with:
                  TIMOB-6536
                  Sync status:
                  ERROR
                  Last received:
                  Last sent:

                  Git Source Code