Skip to content
This repository has been archived by the owner on Oct 21, 2024. It is now read-only.

Commit

Permalink
deCryptorLib (v0.5.8-f2)
Browse files Browse the repository at this point in the history
- Исправлена ошибка при проверке ключа
  • Loading branch information
romanin-rf committed Dec 12, 2021
1 parent 482a902 commit 125547b
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions deCryptorLib.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,8 @@

class __info__:
name = "deCryptor"
version = "0.5.8-r1"
versionint = 0.581
version = "0.5.8-f2"
versionint = 0.582
authors = ["Роман Слабицкий", "Никита Додзин", "Марк Метелев", "Коломыйцев Алексей"]


Expand Down Expand Up @@ -80,7 +80,7 @@ class deCryptor:
def __init__(self, *, speed_mode=False) -> None:
self.speed_mode = speed_mode if (__config__.work_speed_mod) else False

def test_key(key: bytes) -> bool:
def test_key(self, key: bytes) -> bool:
"""Вернёт булевое значение, если `True`, то значит ключ рабочий, если `False` - то ключ сломан или не являеться ключом"""
try:
fernet = Fernet(key)
Expand Down Expand Up @@ -126,7 +126,7 @@ def encode(self, path: str, key_path: str = None) -> dict:
return {"type": "error", "data": "failed_to_load_key_file"}

# Тестирование ключа
if not (self.test_key(key)):
if not(self.test_key(key)):
return {"type": "error", "data": "key_file_is_not_working"}

# Создание переменых для работы
Expand Down

0 comments on commit 125547b

Please sign in to comment.