Skip to content

Commit ced47d4

Browse files
committed
minor cleanup
1 parent 60790d5 commit ced47d4

1 file changed

Lines changed: 1 addition & 7 deletions

File tree

src/BuiltinExtensions/ComfyUIBackend/WorkflowGeneratorSteps.cs

Lines changed: 1 addition & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1983,15 +1983,11 @@ WGNodeData ensureAttachedAudio(WGNodeData media)
19831983
}
19841984
WGNodeData appendAudio(WGNodeData combinedAudio, WGNodeData nextAudio)
19851985
{
1986-
if (nextAudio is null)
1987-
{
1988-
return combinedAudio;
1989-
}
19901986
if (combinedAudio is null)
19911987
{
19921988
return nextAudio;
19931989
}
1994-
if (combinedAudio.DataType != WGNodeData.DT_AUDIO || nextAudio.DataType != WGNodeData.DT_AUDIO)
1990+
if (nextAudio is null || combinedAudio.DataType != WGNodeData.DT_AUDIO || nextAudio.DataType != WGNodeData.DT_AUDIO)
19951991
{
19961992
return combinedAudio;
19971993
}
@@ -2015,7 +2011,6 @@ WGNodeData appendAudio(WGNodeData combinedAudio, WGNodeData nextAudio)
20152011
bool saveIntermediate = g.UserInput.Get(T2IParamTypes.OutputIntermediateImages, false);
20162012
T2IModel extendModel = g.UserInput.Get(T2IParamTypes.VideoExtendModel, null) ?? throw new SwarmUserErrorException("You have an '<extend:' block in your prompt, but you don't have a 'Video Extend Model' selected.");
20172013
PromptRegion regionalizer = new(fullRawPrompt);
2018-
List<JArray> vidChunks = [g.CurrentMedia.Path];
20192014
WGNodeData conjoinedLast = g.CurrentMedia;
20202015
WGNodeData conjoinedAudio = ensureAttachedAudio(conjoinedLast)?.AttachedAudio;
20212016
string getWidthNode = g.CreateNode("SwarmImageWidth", new JObject()
@@ -2091,7 +2086,6 @@ WGNodeData appendAudio(WGNodeData combinedAudio, WGNodeData nextAudio)
20912086
["length"] = frames.Value - frameExtendOverlap
20922087
});
20932088
g.CurrentMedia = g.CurrentMedia.WithPath([cutNode, 0]);
2094-
vidChunks.Add(g.CurrentMedia.Path);
20952089
conjoinedAudio = appendAudio(conjoinedAudio, stageWithAudio?.AttachedAudio);
20962090
string batchedNode = g.CreateNode("ImageBatch", new JObject()
20972091
{

0 commit comments

Comments
 (0)