original_string: public function profileRules()
      {
          return [
              [['username', 'password', 'email'], 'required', 'on' => self::SCENARIO_CREATE],
  
              ['username', 'match', 'pattern' => '/^[A-Za-z][A-Za-z0-9\-\.\ ]+$/i',
                  'message' => Yii::t($this->tcModule, 'Only latin letters, digits, hyphen, points and blanks begin with letter')
              ],
              ['username', 'string', 'min' => $this->minUsernameLength, 'max' => $this->maxUsernameLength],
  
              ['password', 'string', 'min' => $this->minPasswordLength, 'max' => $this->maxPasswordLength],
  
              ['email', 'string', 'max' => 255],
              ['email', 'email'],
          ];
      }
code: public function profileRules()
      {
          return [
              [['username', 'password', 'email'], 'required', 'on' => self::SCENARIO_CREATE],
  
              ['username', 'match', 'pattern' => '/^[A-Za-z][A-Za-z0-9\-\.\ ]+$/i',
                  'message' => Yii::t($this->tcModule, 'Only latin letters, digits, hyphen, points and blanks begin with letter')
              ],
              ['username', 'string', 'min' => $this->minUsernameLength, 'max' => $this->maxUsernameLength],
  
              ['password', 'string', 'min' => $this->minPasswordLength, 'max' => $this->maxPasswordLength],
  
              ['email', 'string', 'max' => 255],
              ['email', 'email'],
          ];
      }
code_tokens: public function profileRules ( ) { return [ [ [ 'username' , 'password' , 'email' ] , 'required' , 'on' => self :: SCENARIO_CREATE ] , [ 'username' , 'match' , 'pattern' => '/^[A-Za-z][A-Za-z0-9\-\.\ ]+$/i' , 'message' => Yii :: t ( $ this -> tcModule , 'Only latin letters, digits, hyphen, points and blanks begin with letter' ) ] , [ 'username' , 'string' , 'min' => $ this -> minUsernameLength , 'max' => $ this -> maxUsernameLength ] , [ 'password' , 'string' , 'min' => $ this -> minPasswordLength , 'max' => $ this -> maxPasswordLength ] , [ 'email' , 'string' , 'max' => 255 ] , [ 'email' , 'email' ] , ] ; }
docstring: Part of rules for common use with ProfileForm.
  Rules with fields length, patterns be best in single place.
docstring_tokens: Part of rules for common use with ProfileForm . Rules with fields length patterns be best in single place .