Code Duplication    Length = 11-12 lines in 2 locations

code/pagetypes/Forum.php 1 location

@@ 98-109 (lines=12) @@
95
            return true;
96
        }
97
98
        if ($member = Member::currentUser()) {
99
            if ($member->IsSuspended()) {
100
                return false;
101
            }
102
            if ($member->IsBanned()) {
103
                return false;
104
            }
105
106
            if ($this->CanPostType == "LoggedInUsers") {
107
                return true;
108
            }
109
110
            if ($groups = $this->PosterGroups()) {
111
                foreach ($groups as $group) {
112
                    if ($member->inGroup($group)) {

code/pagetypes/ForumHolder.php 1 location

@@ 172-182 (lines=11) @@
169
            return true;
170
        }
171
172
        if ($member) {
173
            if ($member->IsSuspended()) {
174
                return false;
175
            }
176
            if ($member->IsBanned()) {
177
                return false;
178
            }
179
            if ($this->CanPostType == "LoggedInUsers") {
180
                return true;
181
            }
182
183
            if ($groups = $this->PosterGroups()) {
184
                foreach ($groups as $group) {
185
                    if ($member->inGroup($group)) {