fix for querying boolean deviceAttributeEvents from database (#314)