don't call handlers if not defined
added a test for the 'a' key.