phpbb/phpbb3 — pull request #811 by bantu (2012-05-22 00:38:00+00:00)
Title: [ticket/10790] Remove a (kind of) dead code section from submit_pm().

http://tracker.phpbb.com/browse/PHPBB3-10790

The type of $user->data['user_id'] is (almost) guranteed to be integer
since session::session_create() casts it to integer.
The type of $row['user_id'] is only an integer if the DB driver adjusts the
PHP type according to the DB type. This is only done by some of our
not-so-popular DB drivers and is not the case for MySQL.

As such this comparison is (almost) never true and a PM is also sent to the
author itself when it is sent to a group the author is also a member of.

Since this behaviour seems to have been accepted by the communty, the dead
code is removed and current behaviour is kept.

Also, checking this in the loop seems to be a rather bad idea.

Introduced by 78b1c4caaa17cc8760b685ad41c19f15f9d89b68.

PHPBB3-10790