original_string: public function scanApp()
      {
          $appNamespace = Configure::read('App.namespace');
          $appShells = $this->scanDir(
              App::path('Shell')[0],
              $appNamespace . '\Shell\\',
              '',
              []
          );
          $appCommands = $this->scanDir(
              App::path('Command')[0],
              $appNamespace . '\Command\\',
              '',
              []
          );
  
          return array_merge($appShells, $appCommands);
      }
code: public function scanApp()
      {
          $appNamespace = Configure::read('App.namespace');
          $appShells = $this->scanDir(
              App::path('Shell')[0],
              $appNamespace . '\Shell\\',
              '',
              []
          );
          $appCommands = $this->scanDir(
              App::path('Command')[0],
              $appNamespace . '\Command\\',
              '',
              []
          );
  
          return array_merge($appShells, $appCommands);
      }
code_tokens: public function scanApp ( ) { $ appNamespace = Configure :: read ( 'App.namespace' ) ; $ appShells = $ this -> scanDir ( App :: path ( 'Shell' ) [ 0 ] , $ appNamespace . '\Shell\\' , '' , [ ] ) ; $ appCommands = $ this -> scanDir ( App :: path ( 'Command' ) [ 0 ] , $ appNamespace . '\Command\\' , '' , [ ] ) ; return array_merge ( $ appShells , $ appCommands ) ; }
docstring: Scan the application for shells & commands.
  
  @return array A list of command metadata.
docstring_tokens: Scan the application for shells & commands .