Skip to content
This repository has been archived by the owner on Sep 18, 2024. It is now read-only.

Commit

Permalink
exclude init and build functions from subclasses
Browse files Browse the repository at this point in the history
  • Loading branch information
Rwolfe-Nava committed Aug 5, 2024
1 parent bc1927d commit dc9f2f4
Showing 1 changed file with 0 additions and 12 deletions.
12 changes: 0 additions & 12 deletions api/src/api/schemas/search_schema.py
Original file line number Diff line number Diff line change
Expand Up @@ -80,9 +80,6 @@ class OpportunitySearchFilterSchema(Schema):
)
"""

def __init__(self, schema_class_name: str):
super().__init__(schema_class_name)

def with_one_of(
self,
*,
Expand Down Expand Up @@ -111,9 +108,6 @@ def with_one_of(

return self

def build(self) -> Schema:
return super().build()


class DateSearchSchemaBuilder(BaseSearchSchemaBuilder):
"""
Expand Down Expand Up @@ -155,16 +149,10 @@ class DateSearchSchemaBuilder(BaseSearchSchemaBuilder):
)
"""

def __init__(self, schema_class_name: str):
super().__init__(schema_class_name)

def with_start_date(self) -> "DateSearchSchemaBuilder":
self.schema_fields["start_date"] = fields.Date(allow_none=True)
return self

def with_end_date(self) -> "DateSearchSchemaBuilder":
self.schema_fields["end_date"] = fields.Date(allow_none=True)
return self

def build(self) -> Schema:
return super().build()

0 comments on commit dc9f2f4

Please sign in to comment.