Browse Source

add getAll()

tags/v0.1.0
MasterOfTheSoftware 2 weeks ago
parent
commit
8db1b894d5
1 changed files with 14 additions and 0 deletions
  1. 14
    0
      bver.py

+ 14
- 0
bver.py View File

@@ -22,3 +22,17 @@ def parse(version_to_parse):
data = version

return data

def getAll(field, value):
versions = getTranslations()

data = []
for version in versions:
try:
if version[field].lower() == value.lower():
data.append(version)

except KeyError: # some translations don't have certain information, thus raising a KeyError
continue

return data

Loading…
Cancel
Save