handle slightly more complex case