original_string: public function get_favourite(string $component, string $itemtype, int $itemid, \context $context) {
          try {
              return $this->repo->find_favourite(
                  $this->userid,
                  $component,
                  $itemtype,
                  $itemid,
                  $context->id
              );
          } catch (\dml_missing_record_exception $e) {
              return null;
          }
      }
code: public function get_favourite(string $component, string $itemtype, int $itemid, \context $context) {
          try {
              return $this->repo->find_favourite(
                  $this->userid,
                  $component,
                  $itemtype,
                  $itemid,
                  $context->id
              );
          } catch (\dml_missing_record_exception $e) {
              return null;
          }
      }
code_tokens: public function get_favourite ( string $ component , string $ itemtype , int $ itemid , \ context $ context ) { try { return $ this -> repo -> find_favourite ( $ this -> userid , $ component , $ itemtype , $ itemid , $ context -> id ) ; } catch ( \ dml_missing_record_exception $ e ) { return null ; } }
docstring: Get the favourite.
  
  @param string $component the frankenstyle component name.
  @param string $itemtype the type of the favourited item.
  @param int $itemid the id of the item which was favourited (not the favourite's id).
  @param \context $context the context of the item which was favourited.
  @return favourite|null
docstring_tokens: Get the favourite .