File tree Expand file tree Collapse file tree 3 files changed +4
-5
lines changed
Expand file tree Collapse file tree 3 files changed +4
-5
lines changed Original file line number Diff line number Diff line change @@ -99,8 +99,7 @@ def add_worms_taxon(
9999 aphia_id : int ,
100100 current_user_id : UserIDT ,
101101 ) -> Any :
102- _user = RightsBO .user_can_add_taxonomy (self .ro_session , current_user_id )
103- current_user : User = self .session .query (User ).get (current_user_id )
102+ current_user = RightsBO .user_can_add_taxonomy (self .ro_session , current_user_id )
104103 taxon = {"aphia_id" : aphia_id , "creator_email" : current_user .email }
105104 ret = self .client .call ("/addwormstaxon/" , taxon )
106105 return ret .json ()
Original file line number Diff line number Diff line change @@ -230,7 +230,7 @@ def get_allowed_actions(user: User) -> List[Action]:
230230 a_priv : ProjectPrivilege
231231 for a_priv in user .privs_on_projects :
232232 if a_priv .privilege == ProjectPrivilegeBO .MANAGE :
233- # If any is managed, OK
233+ # If any is managed, OK for managing a bit of taxo
234234 ret .append (Action .CREATE_TAXON )
235235 break
236236 return ret
Original file line number Diff line number Diff line change @@ -3500,7 +3500,7 @@ def matching_with_worms_nice(
35003500 "/searchworms/{name}" ,
35013501 operation_id = "search_worms_name" ,
35023502 tags = ["Taxonomy Tree" ],
3503- response_model = Optional [List [Dict ]],
3503+ response_model = Optional [List [Dict ]], # type:ignore
35043504)
35053505def search_worms_name (
35063506 name : str ,
@@ -3518,7 +3518,7 @@ def search_worms_name(
35183518 "/addworms/" ,
35193519 operation_id = "add_worms_taxon" ,
35203520 tags = ["Taxonomy Tree" ],
3521- response_model = Any ,
3521+ response_model = Any , # type:ignore
35223522)
35233523def add_worms_taxon (
35243524 taxon : AddWormsTaxonModel = Body (...),
You can’t perform that action at this time.
0 commit comments