Code Duplication    Length = 11-12 lines in 2 locations

code/pagetypes/Forum.php 1 location

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

code/pagetypes/ForumHolder.php 1 location

@@ 165-175 (lines=11) @@
162
            return true;
163
        }
164
165
        if ($member) {
166
            if ($member->IsSuspended()) {
167
                return false;
168
            }
169
            if ($member->IsBanned()) {
170
                return false;
171
            }
172
            if ($this->CanPostType == "LoggedInUsers") {
173
                return true;
174
            }
175
176
            if ($groups = $this->PosterGroups()) {
177
                foreach ($groups as $group) {
178
                    if ($member->inGroup($group)) {