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

The getter for hmiLevel in SDLOnLockScreenStatus doesn't work #83

Closed
jacobkeeler opened this issue Feb 16, 2015 · 0 comments
Closed

The getter for hmiLevel in SDLOnLockScreenStatus doesn't work #83

jacobkeeler opened this issue Feb 16, 2015 · 0 comments
Labels
bug A defect in the library

Comments

@jacobkeeler
Copy link

In SDLOnLockScreenStatus, there is a copy-paste error which prevents the getter for hmiLevel from working properly:

- (SDLHMILevel *)hmiLevel {
    NSObject* obj = [parameters objectForKey:@"hmilevel"];
    if ([obj isKindOfClass:SDLLockScreenStatus.class]) {
        return (SDLHMILevel *)obj;
    } else {
        return [SDLHMILevel valueOf:(NSString*)obj];
    }
}

The if statement in the getter looks for objects of the SDLLockScreenStatus type rather than SDLHMILevel as it should.

if ([obj isKindOfClass:SDLLockScreenStatus.class]) {

Should be:

if ([obj isKindOfClass:SDLHMILevel.class]) {
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug A defect in the library
Projects
None yet
Development

No branches or pull requests

2 participants