Pepguy commited on
Commit
ab5ea02
·
verified ·
1 Parent(s): a4fa12e

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +2 -2
app.py CHANGED
@@ -86,7 +86,7 @@ def map_type_to_category(item_type: str) -> str:
86
  Falls back to 'unknown' if no reasonable match is found.
87
  """
88
  if not item_type:
89
- return "unknown"
90
  t = item_type.strip().lower()
91
  # direct hit
92
  if t in CATEGORIES:
@@ -103,7 +103,7 @@ def map_type_to_category(item_type: str) -> str:
103
  for token in t.replace("_", " ").split():
104
  if token in CATEGORIES:
105
  return token
106
- return "unknown"
107
 
108
 
109
  # ---------- Firebase init helpers ----------
 
86
  Falls back to 'unknown' if no reasonable match is found.
87
  """
88
  if not item_type:
89
+ return "others"
90
  t = item_type.strip().lower()
91
  # direct hit
92
  if t in CATEGORIES:
 
103
  for token in t.replace("_", " ").split():
104
  if token in CATEGORIES:
105
  return token
106
+ return "others"
107
 
108
 
109
  # ---------- Firebase init helpers ----------