Properly check if API instances need overwriting
This commit is contained in:
parent
7fe51c340a
commit
7e3584d5ee
@ -597,7 +597,7 @@ class FAAPI:
|
|||||||
|
|
||||||
# Get the cached user, updating the API instance if necessary
|
# Get the cached user, updating the API instance if necessary
|
||||||
user = self._usercache[username]
|
user = self._usercache[username]
|
||||||
if not user._api:
|
if user._api is not self:
|
||||||
user._api = self
|
user._api = self
|
||||||
return user
|
return user
|
||||||
|
|
||||||
@ -622,7 +622,7 @@ class FAAPI:
|
|||||||
|
|
||||||
# Get the cached submission, updating the API instance if necessary
|
# Get the cached submission, updating the API instance if necessary
|
||||||
submission = self._submissioncache[id]
|
submission = self._submissioncache[id]
|
||||||
if not submission._api:
|
if submission._api is not self:
|
||||||
submission._api = self
|
submission._api = self
|
||||||
return submission
|
return submission
|
||||||
|
|
||||||
|
|||||||
2
setup.py
2
setup.py
@ -2,7 +2,7 @@ from setuptools import setup, find_packages
|
|||||||
|
|
||||||
setup(
|
setup(
|
||||||
name='FAAPI',
|
name='FAAPI',
|
||||||
version='0.6.2',
|
version='0.6.3',
|
||||||
packages=find_packages(),
|
packages=find_packages(),
|
||||||
url='https://tem.party/gitea/tom/FAAPI',
|
url='https://tem.party/gitea/tom/FAAPI',
|
||||||
license='WTFPL',
|
license='WTFPL',
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user