*/ public static function values(): array { $value = self::raw(); return array_map(fn (string $field) => (string) ($value[$field] ?? ''), array_combine(self::FIELDS, self::FIELDS)); } public static function requireCompleteProfile(): bool { return (bool) (self::raw()['require_complete_profile'] ?? true); } /** * @return array */ private static function raw(): array { return json_decode((string) Setting::where('key', 'setting')->value('value'), true) ?: []; } }