Sometimes it happens that the installed framework stops working correctly and causes errors. In this case, deleting the POD file and reinstalling it can help.
$ sudo gem install cocoapods-deintegrate cocoapods-clean
$ pod deintegrate
$ pod clean
$ rm Podfile