| @@ 186-195 (lines=10) @@ | ||
| 183 | { |
|
| 184 | $where = ''; |
|
| 185 | ||
| 186 | if ($withperm) { |
|
| 187 | $where = sprintf(' |
|
| 188 | WHERE |
|
| 189 | ( fg.group_id IN (%s) |
|
| 190 | OR |
|
| 191 | (fu.user_id = %d AND fg.group_id IN (%s)))', |
|
| 192 | implode(', ', $this->groups), |
|
| 193 | $this->user, |
|
| 194 | implode(', ', $this->groups) |
|
| 195 | ); |
|
| 196 | } |
|
| 197 | ||
| 198 | if (isset($this->language) && preg_match("/^[a-z\-]{2,}$/", $this->language)) { |
|
| @@ 3279-3286 (lines=8) @@ | ||
| 3276 | implode(', ', $this->groups), |
|
| 3277 | $this->user, |
|
| 3278 | implode(', ', $this->groups)); |
|
| 3279 | } else { |
|
| 3280 | return sprintf( |
|
| 3281 | 'AND ( fdg.group_id IN (%s) OR (fdu.user_id = %d OR fdg.group_id IN (%s)) )', |
|
| 3282 | implode(', ', $this->groups), |
|
| 3283 | $this->user, |
|
| 3284 | implode(', ', $this->groups) |
|
| 3285 | ); |
|
| 3286 | } |
|
| 3287 | } else { |
|
| 3288 | if (-1 !== $this->user) { |
|
| 3289 | return sprintf( |
|