Code Duplication    Length = 4-4 lines in 2 locations

main/work/work.lib.php 2 locations

@@ 4221-4224 (lines=4) @@
4218
4219
    $currentDate = substr(api_get_local_time(), 0, 10);
4220
4221
    if (!isset($defaults['expires_on'])) {
4222
        $date = substr($currentDate, 0, 10);
4223
        $defaults['expires_on'] = $date.' 23:59';
4224
    }
4225
4226
    if (!isset($defaults['ends_on'])) {
4227
        $date = substr($currentDate, 0, 10);
@@ 4226-4229 (lines=4) @@
4223
        $defaults['expires_on'] = $date.' 23:59';
4224
    }
4225
4226
    if (!isset($defaults['ends_on'])) {
4227
        $date = substr($currentDate, 0, 10);
4228
        $defaults['ends_on'] = $date.' 23:59';
4229
    }
4230
4231
    $form->addElement('date_time_picker', 'expires_on', get_lang('ExpiresAt'));
4232
    $form->addElement('html', '</div>');