Update for wai >= 3