File tree Expand file tree Collapse file tree 1 file changed +6
-4
lines changed
Expand file tree Collapse file tree 1 file changed +6
-4
lines changed Original file line number Diff line number Diff line change @@ -155,21 +155,23 @@ public function __toString(): string
155155 */
156156 public function render (OutputFormat $ outputFormat ): string
157157 {
158- $ result = $ outputFormat ->comments ($ this );
158+ $ formatter = $ outputFormat ->getFormatter ();
159+ $ result = $ formatter ->comments ($ this );
159160 if (\count ($ this ->selectors ) === 0 ) {
160161 // If all the selectors have been removed, this declaration block becomes invalid
161162 throw new OutputException ('Attempt to print declaration block with missing selector ' , $ this ->lineNumber );
162163 }
163164 $ result .= $ outputFormat ->getContentBeforeDeclarationBlock ();
164- $ result .= $ outputFormat ->implode (
165- $ outputFormat ->spaceBeforeSelectorSeparator () . ', ' . $ outputFormat ->spaceAfterSelectorSeparator (),
165+ $ result .= $ formatter ->implode (
166+ $ formatter ->spaceBeforeSelectorSeparator () . ', ' . $ formatter ->spaceAfterSelectorSeparator (),
166167 $ this ->selectors
167168 );
168169 $ result .= $ outputFormat ->getContentAfterDeclarationBlockSelectors ();
169- $ result .= $ outputFormat ->spaceBeforeOpeningBrace () . '{ ' ;
170+ $ result .= $ formatter ->spaceBeforeOpeningBrace () . '{ ' ;
170171 $ result .= $ this ->renderRules ($ outputFormat );
171172 $ result .= '} ' ;
172173 $ result .= $ outputFormat ->getContentAfterDeclarationBlock ();
174+
173175 return $ result ;
174176 }
175177}
You can’t perform that action at this time.
0 commit comments