Code Duplication    Length = 7-7 lines in 2 locations

code/extensions/TicketExtension.php 2 locations

@@ 110-116 (lines=7) @@
107
        }
108
109
        // Create WaitingList tab
110
        if ($this->owner->WaitingList()->exists()) {
111
            $waitingListLabel = _t('TicketExtension.WaitingList', 'WaitingList');
112
            $fields->addFieldToTab(
113
                "Root.$waitingListLabel",
114
                GridField::create('WaitingList', $waitingListLabel, $this->owner->WaitingList(), GridFieldConfig_RecordEditor::create())
115
            );
116
        }
117
118
        // Create Fields tab
119
        $extraFieldsLabel = _t('TicketExtension.ExtraFields', 'Attendee fields');
@@ 101-107 (lines=7) @@
98
        }
99
100
        // Create Attendees tab
101
        if ($this->owner->Attendees()->exists()) {
102
            $guestListLabel = _t('TicketExtension.GuestList', 'GuestList');
103
            $fields->addFieldToTab(
104
                "Root.$guestListLabel",
105
                GridField::create('Attendees', $guestListLabel, $this->owner->Attendees(), GuestListGridFieldConfig::create($this->owner))
106
            );
107
        }
108
109
        // Create WaitingList tab
110
        if ($this->owner->WaitingList()->exists()) {