Added NSlogs to try to fix the errors