Normalize model_types in fla install advisory for None and single string
This commit is contained in:
parent
f8b28b0024
commit
a7d453175a
1 changed files with 4 additions and 0 deletions
|
|
@ -223,6 +223,10 @@ def _maybe_advise_fla_install(model_types):
|
|||
global _fla_advised
|
||||
if _fla_advised:
|
||||
return
|
||||
if model_types is None:
|
||||
return
|
||||
if isinstance(model_types, str):
|
||||
model_types = [model_types] # a lone string would otherwise iterate chars
|
||||
try:
|
||||
if not any(
|
||||
isinstance(t, str) and t.startswith(FLA_MODEL_TYPE_PREFIXES) for t in model_types
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue