<aside> ⚠️ Comparing non-optional value of type 'Int16' to 'nil'

</aside>

코어 데이터에서 스칼라값을 사용할 때 Optional을 체크해도 닐과는 비교할 수 없다는 에러가 뜬다

코어 데이터에서 Use Scalar Type을 해제하면 비교가 가능하다

Untitled

&ref

http://aplus.rs/2017/handling-core-data-optional-scalar-attributes/

https://stackoverflow.com/questions/27411837/swift-casting-a-nil-core-data-string-as-an-optional-value