diff --git a/data/config.example.lua b/data/config.example.lua index f22e585..974844f 100644 --- a/data/config.example.lua +++ b/data/config.example.lua @@ -1,10 +1,11 @@ -- This is a example config. Items not labeled with `Required.` at the end of the comment, are not required, and can be removed. return { - -- Privatkey in kristwallet format. Should end in -000. Do not share this with anyone. Required. + -- Krist private key in raw format. Do not share this with anyone. Required. + -- If you're using Kristwallet format, this should typically be lowercase and end in -000. pkey = "", - -- The krist name you want to use for the shop. The need for this will be removed later on. Required. + -- The Krist name you want to use for the shop. The need for this will be removed later on. Required. name = "", -- The networkID of your turtle. To get this click the modem your turtle is connected to. diff --git a/src/backend.lua b/src/backend.lua index 8b8881a..ff031e6 100644 --- a/src/backend.lua +++ b/src/backend.lua @@ -41,9 +41,6 @@ logger:info("Message field not found in config. Defaulting to default values.") end --- Make private keys chars in lowercase so it works for sure -config.pkey = config.pkey:lower() - logger:info("Configuration loaded. Waiting for chests to be indexed.") os.pullEvent("kristify:storageRefreshed") diff --git a/src/init.lua b/src/init.lua index 3deb9a0..0afe9c7 100644 --- a/src/init.lua +++ b/src/init.lua @@ -139,9 +139,7 @@ return true end - if configExpect("pkey", "string") then - bAssert(not ctx.utils.endsWith(ctx.config.pkey or "", "-000"), "The given krist privatekey is not in the correct format. It must be in KRISTWALLET. Via KristWeb: Go to Wallets -> find your wallet -> Press \"...\" -> Wallet info -> Private key -> Reveal") - end + configExpect("pkey", "string") if configExpect("name", "string") then bAssert(ctx.utils.endsWith(ctx.config.name or "", ".kst"), "Remove \'.kst\' from the name.") end