Fix errors after upgade