Skip to content

Commit e10690f

Browse files
formatting
1 parent 12ce0c7 commit e10690f

File tree

2 files changed

+9
-9
lines changed

2 files changed

+9
-9
lines changed

contentctl/actions/build.py

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -30,9 +30,7 @@ def execute(self, input_dto: BuildInputDto) -> DirectorOutputDto:
3030
updated_conf_files.update(
3131
conf_output.writeDetections(input_dto.director_output_dto.detections)
3232
)
33-
updated_conf_files.update(
34-
conf_output.writeFbds()
35-
)
33+
updated_conf_files.update(conf_output.writeFbds())
3634
updated_conf_files.update(
3735
conf_output.writeStories(input_dto.director_output_dto.stories)
3836
)

contentctl/output/conf_output.py

Lines changed: 8 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -140,19 +140,21 @@ def _parse_fbd_config_file(self, file_path: pathlib.Path) -> list:
140140
stanzas = []
141141
current_stanza_lines = []
142142

143-
with open(file_path, 'r', encoding='utf-8') as f:
143+
with open(file_path, "r", encoding="utf-8") as f:
144144
for line in f:
145145
stripped_line = line.strip()
146146

147147
# Skip comment lines (lines starting with # after stripping whitespace)
148-
if stripped_line.startswith('#'):
148+
if stripped_line.startswith("#"):
149149
continue
150150

151151
# If we hit a blank line and have accumulated stanza content, finalize the current stanza
152152
if not stripped_line:
153153
if current_stanza_lines:
154-
stanza_content = '\n'.join(current_stanza_lines)
155-
stanza_obj = type('FbdStanza', (), {'content': stanza_content})()
154+
stanza_content = "\n".join(current_stanza_lines)
155+
stanza_obj = type(
156+
"FbdStanza", (), {"content": stanza_content}
157+
)()
156158
stanzas.append(stanza_obj)
157159
current_stanza_lines = []
158160
continue
@@ -161,8 +163,8 @@ def _parse_fbd_config_file(self, file_path: pathlib.Path) -> list:
161163
current_stanza_lines.append(line.rstrip())
162164
# Handle the last stanza if the file doesn't end with a blank line
163165
if current_stanza_lines:
164-
stanza_content = '\n'.join(current_stanza_lines)
165-
stanza_obj = type('FbdStanza', (), {'content': stanza_content})()
166+
stanza_content = "\n".join(current_stanza_lines)
167+
stanza_obj = type("FbdStanza", (), {"content": stanza_content})()
166168
stanzas.append(stanza_obj)
167169

168170
return stanzas

0 commit comments

Comments
 (0)