title: How to check action is called by twig renderer or not
body: <p>An action can be called by HTTP request or it can be called by Twig renderer function.</p>
  
  <pre><code>{{ render(controller('MohebifarPaymentBundle:Default:shetab')) }}
  </code></pre>
  
  <p>I want to detect when twig renderer called the action and do somewhat in action.</p>
  
  <pre><code>public function shetabAction() {
      ...
  
      if(ACTION_IS_CALLED_BY_RENDERER) {
  
          // Action is called by Twig renderer
  
      } else { 
  
          // Action is called by HTTP request
  
      }
  
      ...
  }
  </code></pre>
  
  <p>Is there any statement to check that ?</p>