Cannot start strapi after editing localized type

System Information
  • Strapi Version: 4.1.5
  • Operating System: Windows 10
  • Database: postgresql 12.10-2
  • Node Version: v16.15.0
  • NPM Version:
  • Yarn Version: 3.1.1

PS C:\Users\Zander Koch\Documents\GitHub\website\backend> yarn strapi start
[2022-05-09 10:08:15.952] debug: :no_entry: Server wasn’t able to start properly.
[2022-05-09 10:08:15.954] error: Cannot read properties of undefined (reading ‘routes’)
TypeError: Cannot read properties of undefined (reading ‘routes’)
at Object.addCreateLocalizationAction (C:\Users\Zander Koch\Documents\GitHub\website\backend\node_modules@strapi\plugin-i18n\server\services\core-api.js:182:41)
at C:\Users\Zander Koch\Documents\GitHub\website\backend\node_modules@strapi\plugin-i18n\server\register.js:78:22
at Array.forEach ()
at extendLocalizedContentTypes (C:\Users\Zander Koch\Documents\GitHub\website\backend\node_modules@strapi\plugin-i18n\server\register.js:56:38)
at Object.module.exports [as register] (C:\Users\Zander Koch\Documents\GitHub\website\backend\node_modules@strapi\plugin-i18n\server\register.js:12:3)
at Object.register (C:\Users\Zander Koch\Documents\GitHub\website\backend\node_modules@strapi\strapi\lib\core\domain\module\index.js:47:46)
at Object.register (C:\Users\Zander Koch\Documents\GitHub\website\backend\node_modules@strapi\strapi\lib\core\registries\modules.js:33:19)
at async Strapi.runLifecyclesFunctions (C:\Users\Zander Koch\Documents\GitHub\website\backend\node_modules@strapi\strapi\lib\Strapi.js:466:5)
at async Strapi.register (C:\Users\Zander Koch\Documents\GitHub\website\backend\node_modules@strapi\strapi\lib\Strapi.js:337:5)
at async Strapi.load (C:\Users\Zander Koch\Documents\GitHub\website\backend\node_modules@strapi\strapi\lib\Strapi.js:412:5)
at async Strapi.start (C:\Users\Zander Koch\Documents\GitHub\website\backend\node_modules@strapi\strapi\lib\Strapi.js:161:9)

I started getting this error after I changed a collection type to a single type.
I have tried to revert to a working comitt, getting rid of the database I’m using, reinstalling strapi, replacing my node_modules@strapi folder with a copy of a coworker’s , reinstalling strapi again, and reinstalling node.js

This can be closed or deleted, I solved the problem I was having.

Can you please share how you fix it? I’m running into the same issue.

I have the same problem, after changed a collection type to a single