Alt did you stop and or remove MySQL? Also, did you backup your MySQL database and restore it under MariaDB? Keep in mind that even though MariaDB is a fork of MySQL, it is it's own RDMS and databases from your MySQL installation will not copy over. Be sure to create the same database in your MariaDB instance before you try to import your database backup.
Edit: I also need to know how you did the transition, whether it was through your own VPS or web-server stacks such as WAMP/XAMPP.
In any case, please verify what port MariaDB is using, often, if you have MySQL installed under the same server and it is still running, MariaDB's setup should ask you to use another port (which is typically port 3307 for MariaDB). If this is the case, just change the port number in your Flarum config and that should gets things up and running again.
Hope this helps 🙂