michaelarmstrong / SuperRecord

A small set of utilities to make working with CoreData and Swift a bit easier.
MIT License
366 stars 27 forks source link

Invalid StackName if target contains space #28

Closed PGLongo closed 9 years ago

PGLongo commented 9 years ago

If the target contains space the model is automatically named with '_' instead of ' ', for example 'Pokemon Ruby Omega' became 'Pokemon_Ruby_Omega'

let stackName = (infoDictionary!["CFBundleName"] as NSString

We could change stackName like this

let stackName = (infoDictionary!["CFBundleName"] as NSString).stringByReplacingOccurrencesOfString(" ", withString: "_")

Maybe we can also change NSString to String.

PGLongo commented 9 years ago

Maybe you can fix in #22

michaelarmstrong commented 9 years ago

I can confirm this will indeed be fixed in #22