Skip to content
This repository was archived by the owner on May 15, 2024. It is now read-only.
This repository was archived by the owner on May 15, 2024. It is now read-only.

Null Exception for AppInfo.Name on iOS #523

@stoff99

Description

@stoff99

Hello @ALL,

Tested with iOS 12 Simulator and iOS 10 on iPhone 7.

The problem is the function GetBundleValue in AppInfo.ios.cs.
static string GetBundleValue(string key)
=> NSBundle.MainBundle.ObjectForInfoDictionary(key).ToString();

The call:
static string PlatformGetName() => GetBundleValue("CFBundleDisplayName") ?? GetBundleValue("CFBundleName");

First it checks with "CFBundleDisplayName" but this is not set as standard. So the NSBundle.MainBundle.ObjectForInfoDictionary(key) return null. So it came to an NullObjectReference because of .ToString();

Please fix this. Currently i manually implemented the CFBundleDisplayName tag in my Info.plist.

Thx Stefan

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions