Answers.Body: <p>It's a known issue you can safely ignore on Craft 2, that's been resolved for Craft 3.</p>
  
  <p>PHP 7.0 (or maybe it was 7.1) changed the way that particular error was reported from <code>E_STRICT</code> (which Craft 2 is suppressing) to <code>E_WARNING</code>, which Craft 2 isn't suppressing, so now it pops up on latter versions of PHP.</p>
  
Answers.ContentLicense: CC BY-SA 3.0
Answers.CreationDate: 2017-10-03T14:34:10.443Z
Answers.Text: Is there any chance of this fix being back-ported to Craft 2 at all? I've got a site that has over 1,000 of these errors in the PHP Errors log in less than 1 hour, which seems excessive and might mean I miss some important errors due to the noise. In fact, I suspect all my Craft 2 sites will have this too.
Answers.UserDisplayName: Stephen
Answers.ContentLicense: CC BY-SA 3.0
Answers.CreationDate: 2017-06-14T21:14:19.213Z
Answers.LastActivityDate: 2017-06-14T21:14:19.213Z
Answers.UserDisplayName: Brad Bell
Body: <p>I've migrated my Craft project from CentOS/PHP5 to Ubuntu/PHP7 ---  since then I'm seeing this message in /craft/storage/runtime/logs/phperrors.log</p>
  
  <pre><code>[14-Jun-2017 14:40:49 UTC] PHP Warning:  Declaration of Craft\UserSessionService::login($username, $password, $rememberMe = false) should be compatible with CWebUser::login($identity, $duration = 0) in /home/hidden/craft/app/services/UserSessionService.php on line 17
  [14-Jun-2017 14:40:49 UTC] PHP Warning:  Declaration of Craft\UserSessionService::afterLogin() should be compatible with CWebUser::afterLogin($fromCookie) in /home/hidden/craft/app/services/UserSessionService.php on line 17
  [14-Jun-2017 15:50:53 UTC] PHP Warning:  Declaration of Craft\UserSessionService::login($username, $password, $rememberMe = false) should be compatible with CWebUser::login($identity, $duration = 0) in /home/hidden/craft/app/services/UserSessionService.php on line 17
  [14-Jun-2017 15:50:53 UTC] PHP Warning:  Declaration of Craft\UserSessionService::afterLogin() should be compatible with CWebUser::afterLogin($fromCookie) in /home/hidden/craft/app/services/UserSessionService.php on line 17
  [14-Jun-2017 16:03:04 UTC] PHP Warning:  Declaration of Craft\UserSessionService::login($username, $password, $rememberMe = false) should be compatible with CWebUser::login($identity, $duration = 0) in /home/hidden/craft/app/services/UserSessionService.php on line 17
  [14-Jun-2017 16:03:04 UTC] PHP Warning:  Declaration of Craft\UserSessionService::afterLogin() should be compatible with CWebUser::afterLogin($fromCookie) in /home/hidden/craft/app/services/UserSessionService.php on line 17
  </code></pre>
  
  <p>Any Help?</p>
  
Tags: <php>
Title: CraftCMS > UserSessionService should be compatible with CWebUser
ThreadText: # CraftCMS > UserSessionService should be compatible with CWebUser
  
  (Asked by: username_0 on 2017-06-14)
  
  I've migrated my Craft project from CentOS/PHP5 to Ubuntu/PHP7 --- since then I'm seeing this message in /craft/storage/runtime/logs/phperrors.log
  
  ```
  [14-Jun-2017 14:40:49 UTC] PHP Warning:  Declaration of Craft\UserSessionService::login($username, $password, $rememberMe = false) should be compatible with CWebUser::login($identity, $duration = 0) in /home/hidden/craft/app/services/UserSessionService.php on line 17
  [14-Jun-2017 14:40:49 UTC] PHP Warning:  Declaration of Craft\UserSessionService::afterLogin() should be compatible with CWebUser::afterLogin($fromCookie) in /home/hidden/craft/app/services/UserSessionService.php on line 17
  [14-Jun-2017 15:50:53 UTC] PHP Warning:  Declaration of Craft\UserSessionService::login($username, $password, $rememberMe = false) should be compatible with CWebUser::login($identity, $duration = 0) in /home/hidden/craft/app/services/UserSessionService.php on line 17
  [14-Jun-2017 15:50:53 UTC] PHP Warning:  Declaration of Craft\UserSessionService::afterLogin() should be compatible with CWebUser::afterLogin($fromCookie) in /home/hidden/craft/app/services/UserSessionService.php on line 17
  [14-Jun-2017 16:03:04 UTC] PHP Warning:  Declaration of Craft\UserSessionService::login($username, $password, $rememberMe = false) should be compatible with CWebUser::login($identity, $duration = 0) in /home/hidden/craft/app/services/UserSessionService.php on line 17
  [14-Jun-2017 16:03:04 UTC] PHP Warning:  Declaration of Craft\UserSessionService::afterLogin() should be compatible with CWebUser::afterLogin($fromCookie) in /home/hidden/craft/app/services/UserSessionService.php on line 17
  
  ```
  
  Any Help?
  
  **Tags:** php
  
  
  ---
  
  ## 1 answers
  
  ### Answer by username_1 on 2017-06-14. Score: 6
  
  It's a known issue you can safely ignore on Craft 2, that's been resolved for Craft 3.
  
  PHP 7.0 (or maybe it was 7.1) changed the way that particular error was reported from `E_STRICT` (which Craft 2 is suppressing) to `E_WARNING`, which Craft 2 isn't suppressing, so now it pops up on latter versions of PHP.
  
  > **Comments:**
  > **username_2**: Is there any chance of this fix being back-ported to Craft 2 at all? I've got a site that has over 1,000 of these errors in the PHP Errors log in less than 1 hour, which seems excessive and might mean I miss some important errors due to the noise. In fact, I suspect all my Craft 2 sites will have this too.  
  
  ---
  
  