MCPcopy Index your code
hub / github.com/pyfa-org/Pyfa / getitemname

Function getitemname

scripts/itemDiff.py:118–133  ·  view source on GitHub ↗

Get item name from the new db

(item)

Source from the content-addressed store, hash-verified

116
117 itemnames = {}
118 def getitemname(item):
119 """Get item name from the new db"""
120 if item in itemnames:
121 name = itemnames[item]
122 else:
123 query = 'SELECT typeName FROM invtypes WHERE typeID = ?'
124 new_cursor.execute(query, (item,))
125 name = ""
126 for row in new_cursor:
127 name = row[0]
128 if not name:
129 old_cursor.execute(query, (item,))
130 for row in old_cursor:
131 name = row[0]
132 itemnames[item] = name
133 return name
134
135 groupnames = {}
136 def getgroupname(grp):

Callers 1

mainFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected