MongooseServerSelectionError: Could not connect to any servers in your MongoDB Atlas cluster even though Allow Access from anywhere is set

I’m getting this error while trying to connect to mongoose.

/home/runner/SkrivInBussar/node_modules/mongoose/lib/connection.js:755
    err = new ServerSelectionError();
          ^

MongooseServerSelectionError: Could not connect to any servers in your MongoDB Atlas cluster. One common reason is that you're trying to access the database from an IP that isn't whitelisted. Make sure your current IP address is on your Atlas cluster's IP whitelist: https://www.mongodb.com/docs/atlas/security-whitelist/

The thing is that it worked yesterday, and I haven’t changed anything. I have Allow access from anywhere enabled, and my password + user both works. Is the problem due to some rate limit or something?

I’m using a free shared cluster on mongoDB.

await mongoose.connect("mongodb+srv://<user>:<pw>@Bussar.s5cyugd.mongodb.net/bussdb?retryWrites=true&w=majority"