We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 1cd14a7 commit bd23a60Copy full SHA for bd23a60
django_object_actions/templates/django_object_actions/include.js
@@ -14,4 +14,10 @@ admin staticfiles.
14
{% endcomment %}
15
*/
16
/* global: $ */
17
-$('li.objectaction-item').prependTo($('#content-main ul.object-tools'));
+var $items = $('li.objectaction-item'),
18
+ $container = $('#content-main ul.object-tools');
19
+if ($container.length){
20
+ $items.prependTo($container);
21
+} else {
22
+ $items.remove();
23
+}
0 commit comments