Protect against NullPointerException

To fix this issue https://github.com/47deg/android-swipelistview/issues/203
Merge pull request #204 from KibiH/master

Protect against NullPointerException