mirror of
https://github.com/inventree/InvenTree.git
synced 2026-03-12 07:03:36 +00:00
(cherry picked from commit fb3b1189fd)
Co-authored-by: Oliver <oliver.henry.walters@gmail.com>
This commit is contained in:
committed by
GitHub
parent
b611960d9f
commit
c35ab145a4
@@ -587,7 +587,10 @@ def update_exchange_rates(force: bool = False):
|
||||
Arguments:
|
||||
force: If True, force the update to run regardless of the last update time
|
||||
"""
|
||||
from InvenTree.ready import canAppAccessDatabase
|
||||
from InvenTree.ready import canAppAccessDatabase, isRunningMigrations
|
||||
|
||||
if isRunningMigrations():
|
||||
return
|
||||
|
||||
# Do not update exchange rates if we cannot access the database
|
||||
if not canAppAccessDatabase(allow_test=True, allow_shell=True):
|
||||
|
||||
Reference in New Issue
Block a user