     println("//MARK: - Storyboards")
     println("enum Storyboards: String {")
     for storyboard in storyboards {
-        let storyboardName = storyboard.lastPathComponent.stringByDeletingPathExtension
+        let storyboardName = storyboard.storyboardName
         println("    case \(storyboardName) = \"\(storyboardName)\"")
     }
     println()

            }
        }
    }
}

func processStoryboards(storyboards: [String], os: OS) {
    println("//")
    println("// Autogenerated by Natalie - Storyboard Generator Script.")
    println("// http://blog.krzyzanowskim.com")

                        println("            }")
                        println("        }")
                        println()
                        println("        var destination: \(self.os.storyboardControllerReturnType).Type? {")
                        println("            switch (self) {")
                        for segue in segues {
                            if let identifier = segue.element?.attributes["identifier"],
