Skip to content
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Next Next commit
Update auth.hpp
  • Loading branch information
Shxde1 authored Jan 29, 2025
commit ab20de7819f2330e74656677ec4c0de06904ffa2
12 changes: 8 additions & 4 deletions auth.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -18,8 +18,8 @@ namespace KeyAuth {
std::string name, ownerid, version, url, path;
static bool debug;

api(std::string name, std::string ownerid, std::string version, std::string url, std::string path, bool debug = true) {
debug = debug;
api(std::string name, std::string ownerid, std::string version, std::string url, std::string path, bool debugParameter = true) {
setDebug(debugParameter);
}

void ban(std::string reason = "");
Expand Down Expand Up @@ -107,7 +107,9 @@ namespace KeyAuth {

static std::string req(std::string data, std::string url);

static void debugInfo(std::string data, std::string url, std::string response, std::string headers);
void debugInfo(std::string data, std::string url, std::string response, std::string headers);

static void setDebug(bool value);


void load_user_data(nlohmann::json data) {
Expand Down Expand Up @@ -136,8 +138,10 @@ namespace KeyAuth {
api::app_data.numKeys = data[XorStr("numKeys")];
api::app_data.version = data[XorStr("version")];
api::app_data.customerPanelLink = data[XorStr("customerPanelLink")];
std::cout << data;
//api::app_data.downloadLink = data[XorStr("download")];
}

void load_response_data(nlohmann::json data) {
api::response.success = data[XorStr("success")];
api::response.message = data["message"];
Expand Down