Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Open sidebar
drupal.org
better_formats
Commits
204bd3e2
Commit
204bd3e2
authored
Jul 15, 2012
by
dragonwize
Browse files
Fixed empty fieldset from showing some times.
parent
17c7c18f
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
6 additions
and
5 deletions
+6
-5
better_formats.module
better_formats.module
+6
-5
No files found.
better_formats.module
View file @
204bd3e2
...
...
@@ -104,11 +104,6 @@ function better_formats_filter_process_format($element) {
if
(
!
$show_tips_link
)
{
$element
[
'format'
][
'help'
][
'#access'
]
=
FALSE
;
}
// Hide the entire text format fieldset if the user is not supposed to see
// anything inside it.
if
(
!
$show_selection
&&
!
$show_tips
&&
!
$show_tips_link
)
{
$element
[
'format'
][
'#access'
]
=
FALSE
;
}
// If the element represents a field attached to an entity, we may need to
// adjust the allowed text format options. However, we don't want to touch
...
...
@@ -202,6 +197,12 @@ function better_formats_filter_process_format($element) {
}
}
// Hide the entire text format fieldset if the user is not supposed to see
// anything inside it.
if
(
!
$show_selection
&&
!
$show_tips
&&
!
$show_tips_link
)
{
$element
[
'format'
][
'#access'
]
=
FALSE
;
}
return
$element
;
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment