I know, that calling SQL queries in template files is bad practise. But is it bad practise also for theme functions?
For example when my form is rendering with my custom theme function:
<?php $form['#theme'] = '_my_custom_theme_form_method'; ?>
My custom method *_my_custom_theme_form_method* is placed in .module file. Is it the same bad practise as it is for template files?
Is it any serious performance issue, calling SQL queries form theme method?