Update to match the latest API