THIS should solve the naming problem
new class for the Proposals, only outputs their names if name contains "Proposal ", that gets cropped out if no proposal is specified the name of the sample shall not include one
This commit is contained in:
@@ -331,6 +331,14 @@ class Target(Material):
|
||||
self.description = material_data.get("body") or ""
|
||||
|
||||
|
||||
class Proposal:
|
||||
def __init__(self, proposal_data):
|
||||
if "Proposal " in proposal_data["title"]:
|
||||
self.name = proposal_data["title"].replace("Proposal ", "")
|
||||
else:
|
||||
self.name = proposal_data["title"]
|
||||
|
||||
|
||||
if __name__ == "__main__":
|
||||
# head = APIHandler("MyApiKey-123456789abcdef")
|
||||
# print(f"Example header:\n\t{head.header}\n")
|
||||
|
||||
Reference in New Issue
Block a user