Closed gabriel closed 10 years ago
Instead of returning nil in hmacSha256WithKey if item is not NSData, probably better to do an assert?
https://github.com/seb-m/CryptoPill/blob/master/CryptoPill/common/NSArray%2BHMAC.m#L26
NSAssert([item isKindOfClass:[NSData class]], @"Item must be an NSData");
Hi Gabriel,
I think you're right, using an NSAssert is totally appropriate in this case. I've just committed your change 79cb215fe228f7d2869dc0d5aebb32dc8f82a42f. Thanks.
Instead of returning nil in hmacSha256WithKey if item is not NSData, probably better to do an assert?
https://github.com/seb-m/CryptoPill/blob/master/CryptoPill/common/NSArray%2BHMAC.m#L26
NSAssert([item isKindOfClass:[NSData class]], @"Item must be an NSData");