@@ -103,13 +103,13 @@ discard block |
||
103 | 103 | ], |
104 | 104 | |
105 | 105 | /** |
106 | - * Configuration for GeoIP2 |
|
107 | - * Beware, the legacy version does not really work with IPv6 addresses |
|
108 | - * version: set to 2 if you wish to use GeoIP2, to 1 for the legacy version or set to 0 to turn off geolocation service |
|
109 | - * geoip2-path-to-autoloader: points to the GeoIP2 autoloader |
|
110 | - * geoip2-path-to-db: points to the GeoIP2 city database |
|
111 | - * @var array |
|
112 | - */ |
|
106 | + * Configuration for GeoIP2 |
|
107 | + * Beware, the legacy version does not really work with IPv6 addresses |
|
108 | + * version: set to 2 if you wish to use GeoIP2, to 1 for the legacy version or set to 0 to turn off geolocation service |
|
109 | + * geoip2-path-to-autoloader: points to the GeoIP2 autoloader |
|
110 | + * geoip2-path-to-db: points to the GeoIP2 city database |
|
111 | + * @var array |
|
112 | + */ |
|
113 | 113 | |
114 | 114 | 'GEOIP' => [ |
115 | 115 | 'version' => 0, |
@@ -127,7 +127,6 @@ discard block |
||
127 | 127 | * mails, just configure the signing cert with these parameters. All must |
128 | 128 | * be non-NULL for signing to happen. If you don't need a keypass, make |
129 | 129 | * it an empty string instead. |
130 | - |
|
131 | 130 | * @var array |
132 | 131 | */ |
133 | 132 | 'MAILSETTINGS' => [ // we always use Submission |
@@ -146,25 +145,25 @@ discard block |
||
146 | 145 | * @var array |
147 | 146 | */ |
148 | 147 | 'LANGUAGES' => [ |
149 | - 'bg' => ['display' => 'Български', 'locale' => 'bg_BG.utf8', 'latin_based' => FALSE], |
|
150 | - 'ca' => ['display' => 'Català', 'locale' => 'ca_ES.utf8', 'latin_based' => TRUE], |
|
151 | - 'cs' => ['display' => 'Čeština', 'locale' => 'cs_CZ.utf8', 'latin_based' => TRUE], |
|
152 | - 'de' => ['display' => 'Deutsch', 'locale' => 'de_DE.utf8', 'latin_based' => TRUE], |
|
153 | - 'el' => ['display' => 'Ελληνικά', 'locale' => 'el_GR.utf8', 'latin_based' => FALSE], |
|
154 | - 'en' => ['display' => 'English(GB)', 'locale' => 'en_GB.utf8', 'latin_based' => TRUE], |
|
155 | - 'es' => ['display' => 'Español', 'locale' => 'es_ES.utf8', 'latin_based' => TRUE], |
|
156 | - 'fr' => ['display' => 'Français', 'locale' => 'fr_FR.utf8', 'latin_based' => TRUE], |
|
157 | - 'gl' => ['display' => 'Galego', 'locale' => 'gl_ES.utf8', 'latin_based' => TRUE], |
|
158 | - 'hr' => ['display' => 'Hrvatski', 'locale' => 'hr_HR.utf8', 'latin_based' => TRUE], |
|
159 | - 'it' => ['display' => 'Italiano', 'locale' => 'it_IT.utf8', 'latin_based' => TRUE], |
|
160 | - 'lt' => ['display' => 'lietuvių', 'locale' => 'lt_LT.utf8', 'latin_based' => TRUE], |
|
161 | - 'nb' => ['display' => 'Norsk', 'locale' => 'nb_NO.utf8', 'latin_based' => TRUE], |
|
162 | - 'pl' => ['display' => 'Polski', 'locale' => 'pl_PL.utf8', 'latin_based' => TRUE], |
|
163 | - 'sl' => ['display' => 'Slovenščina', 'locale' => 'sl_SI.utf8', 'latin_based' => TRUE], |
|
164 | - 'sr' => ['display' => 'Srpski', 'locale' => 'sr_RS@latin', 'latin_based' => TRUE], |
|
165 | - 'fi' => ['display' => 'Suomi', 'locale' => 'fi_FI.utf8', 'latin_based' => TRUE], |
|
166 | - 'hu' => ['display' => 'Magyar', 'locale' => 'hu_HU.utf8', 'latin_based' => TRUE], |
|
167 | - 'pt' => ['display' => 'Português', 'locale' => 'pt_PT.utf8', 'latin_based' => TRUE], |
|
148 | + 'bg' => ['display' => 'Български', 'locale' => 'bg_BG.utf8', 'latin_based' => FALSE], |
|
149 | + 'ca' => ['display' => 'Català', 'locale' => 'ca_ES.utf8', 'latin_based' => TRUE], |
|
150 | + 'cs' => ['display' => 'Čeština', 'locale' => 'cs_CZ.utf8', 'latin_based' => TRUE], |
|
151 | + 'de' => ['display' => 'Deutsch', 'locale' => 'de_DE.utf8', 'latin_based' => TRUE], |
|
152 | + 'el' => ['display' => 'Ελληνικά', 'locale' => 'el_GR.utf8', 'latin_based' => FALSE], |
|
153 | + 'en' => ['display' => 'English(GB)', 'locale' => 'en_GB.utf8', 'latin_based' => TRUE], |
|
154 | + 'es' => ['display' => 'Español', 'locale' => 'es_ES.utf8', 'latin_based' => TRUE], |
|
155 | + 'fr' => ['display' => 'Français', 'locale' => 'fr_FR.utf8', 'latin_based' => TRUE], |
|
156 | + 'gl' => ['display' => 'Galego', 'locale' => 'gl_ES.utf8', 'latin_based' => TRUE], |
|
157 | + 'hr' => ['display' => 'Hrvatski', 'locale' => 'hr_HR.utf8', 'latin_based' => TRUE], |
|
158 | + 'it' => ['display' => 'Italiano', 'locale' => 'it_IT.utf8', 'latin_based' => TRUE], |
|
159 | + 'lt' => ['display' => 'lietuvių', 'locale' => 'lt_LT.utf8', 'latin_based' => TRUE], |
|
160 | + 'nb' => ['display' => 'Norsk', 'locale' => 'nb_NO.utf8', 'latin_based' => TRUE], |
|
161 | + 'pl' => ['display' => 'Polski', 'locale' => 'pl_PL.utf8', 'latin_based' => TRUE], |
|
162 | + 'sl' => ['display' => 'Slovenščina', 'locale' => 'sl_SI.utf8', 'latin_based' => TRUE], |
|
163 | + 'sr' => ['display' => 'Srpski', 'locale' => 'sr_RS@latin', 'latin_based' => TRUE], |
|
164 | + 'fi' => ['display' => 'Suomi', 'locale' => 'fi_FI.utf8', 'latin_based' => TRUE], |
|
165 | + 'hu' => ['display' => 'Magyar', 'locale' => 'hu_HU.utf8', 'latin_based' => TRUE], |
|
166 | + 'pt' => ['display' => 'Português', 'locale' => 'pt_PT.utf8', 'latin_based' => TRUE], |
|
168 | 167 | |
169 | 168 | // For the following languages, partial translations exist in Transifex, but |
170 | 169 | // they are not complete enough for display. Their Transifex content is not |
@@ -217,11 +216,11 @@ discard block |
||
217 | 216 | 'db' => 'customer_db', |
218 | 217 | 'user' => 'customerservice', |
219 | 218 | 'pass' => '2lame4u'], |
220 | - 'enforce-external-sync' => TRUE, |
|
221 | - /* if you feed your user database from a third-party source and do not want CAT to update it on its own, you can |
|
219 | + 'enforce-external-sync' => TRUE, |
|
220 | + /* if you feed your user database from a third-party source and do not want CAT to update it on its own, you can |
|
222 | 221 | * make it read-only |
223 | 222 | */ |
224 | - 'userdb-readonly' => FALSE, |
|
223 | + 'userdb-readonly' => FALSE, |
|
225 | 224 | ], |
226 | 225 | |
227 | 226 | /** |
@@ -130,7 +130,7 @@ discard block |
||
130 | 130 | |
131 | 131 | * @var array |
132 | 132 | */ |
133 | - 'MAILSETTINGS' => [ // we always use Submission |
|
133 | + 'MAILSETTINGS' => [// we always use Submission |
|
134 | 134 | 'host' => 'submission.capable.mta', |
135 | 135 | 'user'=> 'mailuser', |
136 | 136 | 'pass' => 'mailpass', |
@@ -146,25 +146,25 @@ discard block |
||
146 | 146 | * @var array |
147 | 147 | */ |
148 | 148 | 'LANGUAGES' => [ |
149 | - 'bg' => ['display' => 'Български', 'locale' => 'bg_BG.utf8', 'latin_based' => FALSE], |
|
150 | - 'ca' => ['display' => 'Català', 'locale' => 'ca_ES.utf8', 'latin_based' => TRUE], |
|
151 | - 'cs' => ['display' => 'Čeština', 'locale' => 'cs_CZ.utf8', 'latin_based' => TRUE], |
|
152 | - 'de' => ['display' => 'Deutsch', 'locale' => 'de_DE.utf8', 'latin_based' => TRUE], |
|
153 | - 'el' => ['display' => 'Ελληνικά', 'locale' => 'el_GR.utf8', 'latin_based' => FALSE], |
|
154 | - 'en' => ['display' => 'English(GB)', 'locale' => 'en_GB.utf8', 'latin_based' => TRUE], |
|
155 | - 'es' => ['display' => 'Español', 'locale' => 'es_ES.utf8', 'latin_based' => TRUE], |
|
156 | - 'fr' => ['display' => 'Français', 'locale' => 'fr_FR.utf8', 'latin_based' => TRUE], |
|
157 | - 'gl' => ['display' => 'Galego', 'locale' => 'gl_ES.utf8', 'latin_based' => TRUE], |
|
158 | - 'hr' => ['display' => 'Hrvatski', 'locale' => 'hr_HR.utf8', 'latin_based' => TRUE], |
|
159 | - 'it' => ['display' => 'Italiano', 'locale' => 'it_IT.utf8', 'latin_based' => TRUE], |
|
160 | - 'lt' => ['display' => 'lietuvių', 'locale' => 'lt_LT.utf8', 'latin_based' => TRUE], |
|
161 | - 'nb' => ['display' => 'Norsk', 'locale' => 'nb_NO.utf8', 'latin_based' => TRUE], |
|
162 | - 'pl' => ['display' => 'Polski', 'locale' => 'pl_PL.utf8', 'latin_based' => TRUE], |
|
163 | - 'sl' => ['display' => 'Slovenščina', 'locale' => 'sl_SI.utf8', 'latin_based' => TRUE], |
|
164 | - 'sr' => ['display' => 'Srpski', 'locale' => 'sr_RS@latin', 'latin_based' => TRUE], |
|
165 | - 'fi' => ['display' => 'Suomi', 'locale' => 'fi_FI.utf8', 'latin_based' => TRUE], |
|
166 | - 'hu' => ['display' => 'Magyar', 'locale' => 'hu_HU.utf8', 'latin_based' => TRUE], |
|
167 | - 'pt' => ['display' => 'Português', 'locale' => 'pt_PT.utf8', 'latin_based' => TRUE], |
|
149 | + 'bg' => ['display' => 'Български', 'locale' => 'bg_BG.utf8', 'latin_based' => FALSE], |
|
150 | + 'ca' => ['display' => 'Català', 'locale' => 'ca_ES.utf8', 'latin_based' => TRUE], |
|
151 | + 'cs' => ['display' => 'Čeština', 'locale' => 'cs_CZ.utf8', 'latin_based' => TRUE], |
|
152 | + 'de' => ['display' => 'Deutsch', 'locale' => 'de_DE.utf8', 'latin_based' => TRUE], |
|
153 | + 'el' => ['display' => 'Ελληνικά', 'locale' => 'el_GR.utf8', 'latin_based' => FALSE], |
|
154 | + 'en' => ['display' => 'English(GB)', 'locale' => 'en_GB.utf8', 'latin_based' => TRUE], |
|
155 | + 'es' => ['display' => 'Español', 'locale' => 'es_ES.utf8', 'latin_based' => TRUE], |
|
156 | + 'fr' => ['display' => 'Français', 'locale' => 'fr_FR.utf8', 'latin_based' => TRUE], |
|
157 | + 'gl' => ['display' => 'Galego', 'locale' => 'gl_ES.utf8', 'latin_based' => TRUE], |
|
158 | + 'hr' => ['display' => 'Hrvatski', 'locale' => 'hr_HR.utf8', 'latin_based' => TRUE], |
|
159 | + 'it' => ['display' => 'Italiano', 'locale' => 'it_IT.utf8', 'latin_based' => TRUE], |
|
160 | + 'lt' => ['display' => 'lietuvių', 'locale' => 'lt_LT.utf8', 'latin_based' => TRUE], |
|
161 | + 'nb' => ['display' => 'Norsk', 'locale' => 'nb_NO.utf8', 'latin_based' => TRUE], |
|
162 | + 'pl' => ['display' => 'Polski', 'locale' => 'pl_PL.utf8', 'latin_based' => TRUE], |
|
163 | + 'sl' => ['display' => 'Slovenščina', 'locale' => 'sl_SI.utf8', 'latin_based' => TRUE], |
|
164 | + 'sr' => ['display' => 'Srpski', 'locale' => 'sr_RS@latin', 'latin_based' => TRUE], |
|
165 | + 'fi' => ['display' => 'Suomi', 'locale' => 'fi_FI.utf8', 'latin_based' => TRUE], |
|
166 | + 'hu' => ['display' => 'Magyar', 'locale' => 'hu_HU.utf8', 'latin_based' => TRUE], |
|
167 | + 'pt' => ['display' => 'Português', 'locale' => 'pt_PT.utf8', 'latin_based' => TRUE], |
|
168 | 168 | |
169 | 169 | // For the following languages, partial translations exist in Transifex, but |
170 | 170 | // they are not complete enough for display. Their Transifex content is not |
@@ -61,7 +61,7 @@ discard block |
||
61 | 61 | */ |
62 | 62 | public function __construct() { |
63 | 63 | $this->loggerInstance = new Logging(); |
64 | - $this->loggerInstance->debug(3, "--- BEGIN constructing class ". get_class($this)." .\n"); |
|
64 | + $this->loggerInstance->debug(3, "--- BEGIN constructing class " . get_class($this) . " .\n"); |
|
65 | 65 | $this->languageInstance = new Language(); |
66 | 66 | } |
67 | 67 | |
@@ -71,7 +71,7 @@ discard block |
||
71 | 71 | * Logs the end of lifetime of the entity to the debug log on level 5. |
72 | 72 | */ |
73 | 73 | public function __destruct() { |
74 | - (new Logging())->debug(5,"--- KILL Destructing class ". get_class($this)." .\n"); |
|
74 | + (new Logging())->debug(5, "--- KILL Destructing class " . get_class($this) . " .\n"); |
|
75 | 75 | } |
76 | 76 | |
77 | 77 | /** |
@@ -56,8 +56,8 @@ |
||
56 | 56 | |
57 | 57 | $i = 0; |
58 | 58 | foreach ($salvageFedPrivs as $oneFed) { |
59 | - $_POST['option']["S123456789".$i] = "user:fedadmin#string##"; |
|
60 | - $_POST['value']["S123456789".$i."-0"] = $oneFed; |
|
59 | + $_POST['option']["S123456789" . $i] = "user:fedadmin#string##"; |
|
60 | + $_POST['value']["S123456789" . $i . "-0"] = $oneFed; |
|
61 | 61 | $i++; |
62 | 62 | } |
63 | 63 | ?> |
@@ -26,4 +26,4 @@ |
||
26 | 26 | $Gui->defaultPagePrelude(); |
27 | 27 | |
28 | 28 | // and now, serve actual data |
29 | -include("skins/".$Gui->skinObject->skin."/index.php"); |
|
29 | +include("skins/" . $Gui->skinObject->skin . "/index.php"); |
@@ -11,7 +11,7 @@ discard block |
||
11 | 11 | namespace core\common; |
12 | 12 | use \Exception; |
13 | 13 | |
14 | -require_once(dirname(dirname(__DIR__))."/config/_config.php"); |
|
14 | +require_once(dirname(dirname(__DIR__)) . "/config/_config.php"); |
|
15 | 15 | |
16 | 16 | class Logging { |
17 | 17 | |
@@ -86,7 +86,7 @@ discard block |
||
86 | 86 | echo " ($category) "; |
87 | 87 | echo " " . $user . ": "; |
88 | 88 | if (is_string($message)) { |
89 | - echo $message ."\n"; |
|
89 | + echo $message . "\n"; |
|
90 | 90 | } else { |
91 | 91 | echo var_export($message); |
92 | 92 | } |
@@ -19,7 +19,7 @@ discard block |
||
19 | 19 | * @package ModuleWriting |
20 | 20 | */ |
21 | 21 | namespace devices\xml; |
22 | -require_once(dirname(__FILE__).'/XML.inc.php'); |
|
22 | +require_once(dirname(__FILE__) . '/XML.inc.php'); |
|
23 | 23 | |
24 | 24 | /** |
25 | 25 | * This class implements full functionality of the generic XML device |
@@ -154,7 +154,7 @@ discard block |
||
154 | 154 | $objs = []; |
155 | 155 | if ($this->langScope === 'global') { |
156 | 156 | foreach ($attributeList['langs'] as $language => $value) { |
157 | - $language = ( $language === 'C' ? 'any' : $language ); |
|
157 | + $language = ($language === 'C' ? 'any' : $language); |
|
158 | 158 | $obj = new $className(); |
159 | 159 | $obj->setValue($value); |
160 | 160 | $obj->setAttributes(['lang' => $language]); |
@@ -178,7 +178,7 @@ discard block |
||
178 | 178 | $profileNameLangs = $attr['profile:name']['langs']; |
179 | 179 | } |
180 | 180 | foreach ($instNameLangs as $language => $value) { |
181 | - $language = ( $language === 'C' ? 'any' : $language ); |
|
181 | + $language = ($language === 'C' ? 'any' : $language); |
|
182 | 182 | $displayname = new DisplayName(); |
183 | 183 | if (isset($profileNameLangs)) { |
184 | 184 | $langOrC = isset($profileNameLangs[$language]) ? $profileNameLangs[$language] : $profileNameLangs['C']; |
@@ -351,7 +351,7 @@ discard block |
||
351 | 351 | $clientCertificateObject->setValue(base64_encode($this->clientCert["certdata"])); |
352 | 352 | $clientCertificateObject->setAttributes(['format' => 'PKCS12', 'encoding' => 'base64']); |
353 | 353 | |
354 | - $clientsidecredential->setProperty('ClientCertificate',$clientCertificateObject); |
|
354 | + $clientsidecredential->setProperty('ClientCertificate', $clientCertificateObject); |
|
355 | 355 | } |
356 | 356 | |
357 | 357 | $authmethod->setProperty('ClientSideCredential', $clientsidecredential); |
@@ -12,11 +12,11 @@ discard block |
||
12 | 12 | |
13 | 13 | array_push($FAQ, [ |
14 | 14 | 'title' => sprintf(_("My %s is not listed. Can't I just use any of the other ones?"), $skinObject->nomenclature_inst), |
15 | - 'text' => sprintf(_("No! The installers contain security settings which are specific to the %s. If you are not from that %s, your computer will detect that you are about to send your username and credential to an unauthorised server and will abort the login. Using a different %s installer is <i>guaranteed to not work</i>!"),$skinObject->nomenclature_inst,$skinObject->nomenclature_inst,$skinObject->nomenclature_inst) |
|
15 | + 'text' => sprintf(_("No! The installers contain security settings which are specific to the %s. If you are not from that %s, your computer will detect that you are about to send your username and credential to an unauthorised server and will abort the login. Using a different %s installer is <i>guaranteed to not work</i>!"), $skinObject->nomenclature_inst, $skinObject->nomenclature_inst, $skinObject->nomenclature_inst) |
|
16 | 16 | ]); |
17 | 17 | |
18 | 18 | array_push($FAQ, [ |
19 | - 'title' => sprintf(_("What can I do to get my %s listed?"),$skinObject->nomenclature_inst), |
|
19 | + 'title' => sprintf(_("What can I do to get my %s listed?"), $skinObject->nomenclature_inst), |
|
20 | 20 | 'text' => sprintf(_("Contact %s administrators at your %s and complain. It will take at most one hour of their time to get things done."), CONFIG_CONFASSISTANT['CONSORTIUM']['display_name'], $skinObject->nomenclature_inst) |
21 | 21 | ]); |
22 | 22 | |
@@ -32,14 +32,14 @@ discard block |
||
32 | 32 | |
33 | 33 | if (CONFIG_CONFASSISTANT['CONSORTIUM']['name'] == "eduroam") { |
34 | 34 | array_push($FAQ, [ |
35 | - 'title' => sprintf(_("What is this %s thing anyway?"),CONFIG_CONFASSISTANT['CONSORTIUM']['display_name']), |
|
36 | - 'text' => sprintf(_("%s is a global WiFi roaming consortium which gives members of education and research access to the internet <i>for free</i> on all %s hotspots on the planet. There are several million %s users already, enjoying free internet access on more than 6.000 hotspots! Visit <a href='http://www.eduroam.org'>the %s homepage</a> for more details."),CONFIG_CONFASSISTANT['CONSORTIUM']['display_name'],CONFIG_CONFASSISTANT['CONSORTIUM']['display_name'],CONFIG_CONFASSISTANT['CONSORTIUM']['display_name'],CONFIG_CONFASSISTANT['CONSORTIUM']['display_name']) |
|
35 | + 'title' => sprintf(_("What is this %s thing anyway?"), CONFIG_CONFASSISTANT['CONSORTIUM']['display_name']), |
|
36 | + 'text' => sprintf(_("%s is a global WiFi roaming consortium which gives members of education and research access to the internet <i>for free</i> on all %s hotspots on the planet. There are several million %s users already, enjoying free internet access on more than 6.000 hotspots! Visit <a href='http://www.eduroam.org'>the %s homepage</a> for more details."), CONFIG_CONFASSISTANT['CONSORTIUM']['display_name'], CONFIG_CONFASSISTANT['CONSORTIUM']['display_name'], CONFIG_CONFASSISTANT['CONSORTIUM']['display_name'], CONFIG_CONFASSISTANT['CONSORTIUM']['display_name']) |
|
37 | 37 | ]); |
38 | 38 | } |
39 | 39 | |
40 | 40 | array_push($FAQ, [ |
41 | 41 | 'title' => sprintf(_("Is it safe to use %s installers?"), CONFIG['APPEARANCE']['productname']), |
42 | - 'text' => sprintf(_("%s installers configure security settings on your device, therefore you should be sure that you are using genuine ones."), CONFIG['APPEARANCE']['productname']) . ' ' . ( isset(CONFIG_CONFASSISTANT['CONSORTIUM']['signer_name']) && CONFIG_CONFASSISTANT['CONSORTIUM']['signer_name'] != "" ? sprintf(_("This is why %s installers are digitally signed by %s. Watch out for a system message confirming this."), CONFIG['APPEARANCE']['productname'], CONFIG_CONFASSISTANT['CONSORTIUM']['signer_name']) : ""), |
|
42 | + 'text' => sprintf(_("%s installers configure security settings on your device, therefore you should be sure that you are using genuine ones."), CONFIG['APPEARANCE']['productname']) . ' ' . (isset(CONFIG_CONFASSISTANT['CONSORTIUM']['signer_name']) && CONFIG_CONFASSISTANT['CONSORTIUM']['signer_name'] != "" ? sprintf(_("This is why %s installers are digitally signed by %s. Watch out for a system message confirming this."), CONFIG['APPEARANCE']['productname'], CONFIG_CONFASSISTANT['CONSORTIUM']['signer_name']) : ""), |
|
43 | 43 | ]); |
44 | 44 | |
45 | 45 | array_push($FAQ, [ |
@@ -125,6 +125,7 @@ discard block |
||
125 | 125 | * |
126 | 126 | * @param string $device |
127 | 127 | * @param AbstractProfile $profile |
128 | + * @param string $generatedFor |
|
128 | 129 | * @return array info about the new installer (mime and link) |
129 | 130 | */ |
130 | 131 | private function generateNewInstaller($device, $profile, $generatedFor, $token, $password) { |
@@ -459,6 +460,10 @@ discard block |
||
459 | 460 | readfile($file); |
460 | 461 | } |
461 | 462 | |
463 | + /** |
|
464 | + * @param string $destFile |
|
465 | + * @param integer $resize |
|
466 | + */ |
|
462 | 467 | private function processImage($inputImage, $destFile, $width, $height, $resize) { |
463 | 468 | $info = new \finfo(); |
464 | 469 | $filetype = $info->buffer($inputImage, FILEINFO_MIME_TYPE); |
@@ -485,7 +490,6 @@ discard block |
||
485 | 490 | * When called for DiscoJuice, first check if file cache exists |
486 | 491 | * If not then generate the file and save it in the cache |
487 | 492 | * @param int $idp IdP identifier |
488 | - * @param int $disco flag turning on image generation for DiscoJuice |
|
489 | 493 | * @param int $width maximum width of the generated image |
490 | 494 | * @param int $height maximum height of the generated image |
491 | 495 | * if one of these is 0 then it is treated as no upper bound |
@@ -260,6 +260,9 @@ discard block |
||
260 | 260 | return _("Sorry, this should not happen - no additional information is available"); |
261 | 261 | } |
262 | 262 | |
263 | + /** |
|
264 | + * @param string $file |
|
265 | + */ |
|
263 | 266 | private function findSourceFile($file) { |
264 | 267 | if (is_file($this->module_path . '/Files/' . $this->device_id . '/' . $file)) { |
265 | 268 | return $this->module_path . '/Files/' . $this->device_id . '/' . $file; |
@@ -540,6 +543,9 @@ discard block |
||
540 | 543 | 'application/pdf' => 'pdf', |
541 | 544 | ]; |
542 | 545 | |
546 | + /** |
|
547 | + * @param string $type |
|
548 | + */ |
|
543 | 549 | private function saveLogoFile($logos,$type) { |
544 | 550 | $iterator = 0; |
545 | 551 | $returnarray = []; |
@@ -212,7 +212,7 @@ discard block |
||
212 | 212 | } |
213 | 213 | if (isset($this->attributes['general:logo_file'])) { |
214 | 214 | $this->loggerInstance->debug(5, "saving IDP logo\n"); |
215 | - $this->attributes['internal:logo_file'] = $this->saveLogoFile($this->attributes['general:logo_file'],'idp'); |
|
215 | + $this->attributes['internal:logo_file'] = $this->saveLogoFile($this->attributes['general:logo_file'], 'idp'); |
|
216 | 216 | } |
217 | 217 | if (isset($this->attributes['fed:logo_file'])) { |
218 | 218 | $this->loggerInstance->debug(5, "saving FED logo\n"); |
@@ -540,7 +540,7 @@ discard block |
||
540 | 540 | 'application/pdf' => 'pdf', |
541 | 541 | ]; |
542 | 542 | |
543 | - private function saveLogoFile($logos,$type) { |
|
543 | + private function saveLogoFile($logos, $type) { |
|
544 | 544 | $iterator = 0; |
545 | 545 | $returnarray = []; |
546 | 546 | foreach ($logos as $blob) { |