Skip to content

Commit

Permalink
Merge branch 'release/1.6.1'
Browse files Browse the repository at this point in the history
  • Loading branch information
Misplon committed Nov 26, 2024
2 parents 4a9f967 + 114ff55 commit 4e1be40
Show file tree
Hide file tree
Showing 3 changed files with 12 additions and 9 deletions.
3 changes: 3 additions & 0 deletions changelog.txt
Original file line number Diff line number Diff line change
@@ -1,5 +1,8 @@
== Changelog ==

= 1.6.1 - 25 November 2024 =
* CSS Output Location: Additional check to ensure the default is Dedicated File.

= 1.6.0 - 22 November 2024 =
* Added `Visual Editor: Decoration > Background Attachment` setting.
* Added CSS Ouput Location setting. Dedicated CSS File offers best performance, Internal CSS embeds styles in page HTML.
Expand Down
3 changes: 3 additions & 0 deletions readme.txt
Original file line number Diff line number Diff line change
Expand Up @@ -72,6 +72,9 @@ SiteOrigin Premium includes access to our professional email support service, pe

== Changelog ==

= 1.6.1 - 25 November 2024 =
* CSS Output Location: Additional check to ensure the default is Dedicated File.

= 1.6.0 - 22 November 2024 =
* Added `Visual Editor: Decoration > Background Attachment` setting.
* Added CSS Ouput Location setting. Dedicated CSS File offers best performance, Internal CSS embeds styles in page HTML.
Expand Down
15 changes: 6 additions & 9 deletions so-css.php
Original file line number Diff line number Diff line change
Expand Up @@ -319,11 +319,11 @@ public function enqueue_css() {
*
* This method retrieves the CSS output location setting from the
* `so_css_output_location` option and returns true if the setting is
* set to 'file' and false if it is set to 'inline'.
* set to 'file'. Otherwise false is returned.
*
* @param string|null $location The unused default location value.
*
* @return bool True if the CSS should be output in a dedicated file, false if it should be inline.
* @return bool True if the CSS should be output in a dedicated file.
*/
public function css_output_location( $location = null ) {
$output_location = get_option(
Expand Down Expand Up @@ -1023,13 +1023,10 @@ private function get_latest_revision_timestamp() {
public function version_check() {
$version = get_option( 'so_css_version' );

// If there's no version set, check if this site already
// had SO CSS installed by checking for custom CSS.
if ( empty( $version ) ) {
update_option(
'so_css_output_location',
! empty( $this->get_custom_css( $this->theme ) ) ? 'inline' : 'file'
);
// If there's no version set or it's set to 1.6.0, check if
// this site already had SO CSS installed by checking for custom CSS.
if ( empty( $version ) || $version === '1.6.0' ) {
update_option( 'so_css_output_location', 'file' );
}

if ( empty( $version ) || version_compare( $version, SOCSS_VERSION, '<' ) ) {
Expand Down

0 comments on commit 4e1be40

Please sign in to comment.