I always get in the generic catch
# kotlin-native
s
I always get in the generic catch
Okay, Error need to be converted back to Kotlin Exception type
Copy code
do {
	try Library.companion.getInformation()
}
catch let error as NSError {
	guard let exception = error.kotlinException as? LibraryException else {
		print("Not a LibraryException")
		return
	}
	switch exception {
		case is LibraryException.NotInitialized:
			print("It is NotInitialized!")
		default:
			print("Some other LibraryException")
	}
}