minor improvement: return as early as possible
add test for 'no notifications'