original_string: public static function getRecent($user)
      {
          $records = static::where('user_id', $user->id)
              ->orderBy('created_at', 'desc')
              ->limit(2)
              ->get()
          ;
  
          if (!count($records)) {
              return null;
          }
  
          $first = $records->first();
  
          return !$first->created_at->isToday() ? $first : $records->pop();
      }
code: public static function getRecent($user)
      {
          $records = static::where('user_id', $user->id)
              ->orderBy('created_at', 'desc')
              ->limit(2)
              ->get()
          ;
  
          if (!count($records)) {
              return null;
          }
  
          $first = $records->first();
  
          return !$first->created_at->isToday() ? $first : $records->pop();
      }
code_tokens: public static function getRecent ( $ user ) { $ records = static :: where ( 'user_id' , $ user -> id ) -> orderBy ( 'created_at' , 'desc' ) -> limit ( 2 ) -> get ( ) ; if ( ! count ( $ records ) ) { return null ; } $ first = $ records -> first ( ) ; return ! $ first -> created_at -> isToday ( ) ? $ first : $ records -> pop ( ) ; }
docstring: Returns a recent entry, latest entry is not considered recent
  if the creation day is the same as today.
  @return self
docstring_tokens: Returns a recent entry latest entry is not considered recent if the creation day is the same as today .