Skip to content

Commit

Permalink
Using network id instead of string for getting pocketnet developers
Browse files Browse the repository at this point in the history
  • Loading branch information
lostystyg committed Apr 18, 2022
1 parent 2f23cc8 commit 9722326
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions src/pocketdb/helpers/PocketnetHelper.h
Original file line number Diff line number Diff line change
Expand Up @@ -15,8 +15,8 @@ namespace PocketHelpers
{
using namespace std;

static map<string, vector<string>> PocketnetDevelopers{
{"main", {
static map<NetworkId, vector<string>> PocketnetDevelopers{
{NetworkId::NetworkMain, {
"P9EkPPJPPRYxmK541WJkmH8yBM4GuWDn2m",
"PUGBtfmivvcg1afnEt9vqVi3yZ7v6S9BcC",
"PDtuJDVXaq82HH7fafgwBmcoxbqqWdJ9u9",
Expand All @@ -28,7 +28,7 @@ namespace PocketHelpers
"PMyjUzHtzsmbejB87ATbrcQNatiGsT4NzG",
"PHdW4pwWbFdoofVhSEfPSHgradmrvZdbE5"
}},
{"test", {
{NetworkId::NetworkTest, {
"TG69Jioc81PiwMAJtRanfZqUmRY4TUG7nt",
"TLnfXcFNxxrpEUUzrzZvbW7b9gWFtAcc8x",
"TYMo5HRFpc7tqzccaVifx7s2x2ZDqMikCR",
Expand All @@ -37,7 +37,7 @@ namespace PocketHelpers

static inline bool IsDeveloper(const string& address)
{
auto net = Params().NetworkIDString();
auto net = Params().NetworkID();
return find(PocketnetDevelopers[net].begin(), PocketnetDevelopers[net].end(), address) != PocketnetDevelopers[net].end();
}
}
Expand Down

0 comments on commit 9722326

Please sign in to comment.