Code Duplication    Length = 7-8 lines in 2 locations

lib/private/legacy/util.php 2 locations

@@ 648-654 (lines=7) @@
645
		}
646
647
		// Check if server running on Windows platform
648
		if(OC_Util::runningOnWindows()) {
649
			$errors[] = [
650
				'error' => $l->t('Microsoft Windows Platform is not supported'),
651
				'hint' => $l->t('Running Nextcloud Server on the Microsoft Windows platform is not supported. We suggest you ' .
652
					'use a Linux server in a virtual machine if you have no option for migrating the server itself.')
653
			];
654
		}
655
656
		// Check if config folder is writable.
657
		if(!OC_Helper::isReadOnlyConfigEnabled()) {
@@ 711-718 (lines=8) @@
708
			}
709
		}
710
711
		if (!OC_Util::isSetLocaleWorking()) {
712
			$errors[] = array(
713
				'error' => $l->t('Setting locale to %s failed',
714
					array('en_US.UTF-8/fr_FR.UTF-8/es_ES.UTF-8/de_DE.UTF-8/ru_RU.UTF-8/'
715
						. 'pt_BR.UTF-8/it_IT.UTF-8/ja_JP.UTF-8/zh_CN.UTF-8')),
716
				'hint' => $l->t('Please install one of these locales on your system and restart your webserver.')
717
			);
718
		}
719
720
		// Contains the dependencies that should be checked against
721
		// classes = class_exists