File tree Expand file tree Collapse file tree 1 file changed +1
-6
lines changed
Expand file tree Collapse file tree 1 file changed +1
-6
lines changed Original file line number Diff line number Diff line change @@ -481,18 +481,13 @@ async def register_server(
481481 elif resource_ids :
482482 # Use single query for single item (maintains test compatibility)
483483 resource_obj = db .get (DbResource , resource_ids [0 ])
484- # for resource_id in server_in.associated_resources:
485- # if resource_id.strip() == "":
486- # continue
487- # # Resource IDs are stored as string UUID hex values, not integers.
488- # resource_obj = db.get(DbResource, resource_id)
489484 if not resource_obj :
490485 raise ServerError (f"Resource with id { resource_ids [0 ]} does not exist." )
491486 db_server .resources .append (resource_obj )
492487
493488 # Associate prompts, verifying each exists using bulk query when multiple items
494489 if server_in .associated_prompts :
495- prompt_ids = [int ( prompt_id .strip () ) for prompt_id in server_in .associated_prompts if prompt_id .strip ()]
490+ prompt_ids = [prompt_id .strip () for prompt_id in server_in .associated_prompts if prompt_id .strip ()]
496491 if len (prompt_ids ) > 1 :
497492 # Use bulk query for multiple items
498493 prompts = db .execute (select (DbPrompt ).where (DbPrompt .id .in_ (prompt_ids ))).scalars ().all ()
You can’t perform that action at this time.
0 commit comments