diff include/core/anime_db.h @ 317:b1f4d1867ab1

services: VERY initial Kitsu support it only supports user authentication for now, but it's definitely a start.
author Paper <paper@paper.us.eu.org>
date Wed, 12 Jun 2024 04:07:10 -0400
parents 3ec7804abf17
children d928ec7b6a0d
line wrap: on
line diff
--- a/include/core/anime_db.h	Tue Jun 11 15:11:09 2024 -0400
+++ b/include/core/anime_db.h	Wed Jun 12 04:07:10 2024 -0400
@@ -25,6 +25,12 @@
 
 	bool ParseDatabaseJSON(const nlohmann::json& json);
 	bool LoadDatabaseFromDisk();
+
+	/* These are here to make sure that our service IDs don't collide
+	 * and make the whole thing go boom. */
+	int GetUnusedId();
+	int LookupServiceId(Service service, const std::string& id_to_find);
+	int LookupServiceIdOrUnused(Service service, const std::string& id_to_find);
 };
 
 extern Database db;