feat: trim spaces between title and content

Trim spaces between title and content to avoid unwanted <pre> wraps when using
content next to title separated by a space instead of a new line.
This commit is contained in:
ciencia 2022-04-18 19:43:08 -04:00 committed by alistair3149
parent f9b3892604
commit 98c6f2753a
No known key found for this signature in database
GPG key ID: 94D081060FD3DD9C

View file

@ -66,7 +66,7 @@ class TabberNeueHooks {
}
// Use array_pad to make sure at least 2 array values are always returned
list( $tabName, $tabBody ) = array_pad( explode( '=', $tab, 2 ), 2, '' );
list( $tabName, $tabBody ) = array_pad( array_map( 'trim', explode( '=', $tab, 2 ) ), 2, '' );
// Append __NOEDITSECTION__ to prevent section edit links from being added by the parser
// since section edit links do not work inside a tabber body