-1

i am tying to make my own SnapchatHax and when i am tying to build the app i have a error:

Severity    Code    Description Project File    Line    Suppression State
Error       property 'timeIntervalSince1970' not found on object of type 'id'   SnapchatHax (SnapchatHax\SnapchatHax)   C:\re\SnapchatHax-master\SnapchatHax\Snapchat\Internal\SCAPIRequest.m   14  

here is the code that have the bug:

//  SCAPIRequest.m
//  SnapchatHax
//
//  Created by Alex Nichol on 12/17/13.
//  Copyright (c) 2013 Alex Nichol. All rights reserved.
//

#import "SCAPIRequest.h"

@implementation SCAPIRequest

+ (NSString *)timestampString {\
    NSTimeInterval time = [NSDate date].timeIntervalSince1970;
    return [NSString stringWithFormat:@"%llu", (unsigned long long)round(time * 1000.0)];
}

Thanks everyone

1 Answers1

0

The reason is

[NSDate date] 

is returning a NSDate type of object and you have accessed timeIntervalSince1970 directly from it which of different type. Use

NSTimeInterval value = ((NStimeInterval*)[anArray objectAtIndex:0]).aVariable;

Hope your problem will get solve

Thanks

Appi
  • 54
  • 5