@@ -105,7 +105,7 @@ discard block |
||
105 | 105 | * http://stackoverflow.com/a/43359819/2953830 |
106 | 106 | * |
107 | 107 | * @param $a |
108 | - * @param $b |
|
108 | + * @param integer $b |
|
109 | 109 | * |
110 | 110 | * @return number |
111 | 111 | */ |
@@ -142,7 +142,7 @@ discard block |
||
142 | 142 | * @param string $str |
143 | 143 | * @param int $index |
144 | 144 | * |
145 | - * @return number |
|
145 | + * @return string |
|
146 | 146 | */ |
147 | 147 | private function JS_charCodeAt($str, $index) { |
148 | 148 | $utf16 = mb_convert_encoding($str, 'UTF-16LE', 'UTF-8'); |
@@ -224,7 +224,9 @@ |
||
224 | 224 | * if source lang and target lang are the same |
225 | 225 | * just return the string without any request to google |
226 | 226 | */ |
227 | - if ($this->source == $this->target) return $string; |
|
227 | + if ($this->source == $this->target) { |
|
228 | + return $string; |
|
229 | + } |
|
228 | 230 | |
229 | 231 | $responseArray = $this->getResponse($string); |
230 | 232 |