Add some missing logic