title: Custom function Wordpress not stopping after return
body: <p>Good day!</p>
  
  <p>As the title says my custom function is not stopping after i do return.
  I have created a child theme and create a function inside the functions.php file.</p>
  
  <p>What i try to achieve is show the category title otherwise the string home as title.</p>
  
  <p>What i end up getting now is both the category title and the string of home if i click on a category.</p>
  
  <p>HTML:</p>
  
  <pre><code>&lt;h3&gt;&lt;?php echo header_title() ?&gt; &lt;/h3&gt;
  </code></pre>
  
  <p>PHP:</p>
  
  <pre><code>function header_title() {
  
  
      if(single_cat_title() != NULL) {
          return single_cat_title();
      } else {
          return 'home';
      }
  }
  </code></pre>
  
  <p>Anyone knows what went wrong here?</p>
  
  <p>Any help will be appreciated here :)</p>