added connection check in checkNotify and added documentation