I have code like this in Xcode 6.3:
let store = EKEventStore()
for source in store.sources() {
let st: EKSourceType = source.sourceType!
if st == EKSourceTypeLocal {
localSource = source;
}
}
The fifth line (if st..) gives the complier error: 'Binary operator == cannot be applied to two EKSourceType operands'
How can I check if the source is local or not (in Swift) and get this to compile?
Like this:
if st.value == EKSourceTypeLocal.value
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With