Completed
Push — master ( 62d6d0...3be28e )
by Rudie
02:13
created
IMAP.php 2 patches
Doc Comments   +12 added lines patch added patch discarded remove patch
@@ -116,6 +116,9 @@  discard block
 block discarded – undo
116 116
 		$this->unseen = $unseen;
117 117
 	}
118 118
 
119
+	/**
120
+	 * @param boolean $clear
121
+	 */
119 122
 	protected function flags( $flags, $clear ) {
120 123
 		$cb = $clear ? 'imap_clearflag_full' : 'imap_setflag_full';
121 124
 
@@ -214,6 +217,9 @@  discard block
 block discarded – undo
214 217
 		return $this->parts;
215 218
 	}
216 219
 
220
+	/**
221
+	 * @param string $IMAPMessagePartClass
222
+	 */
217 223
 	protected function messageParts( $parts, $sectionPrefix = array(), $IMAPMessagePartClass ) {
218 224
 		$sectionPrefix = (array)$sectionPrefix;
219 225
 
@@ -263,6 +269,9 @@  discard block
 block discarded – undo
263 269
 		return $this->decode($body);
264 270
 	}
265 271
 
272
+	/**
273
+	 * @param string $content
274
+	 */
266 275
 	public function decode( $content ) {
267 276
 		return quoted_printable_decode($content);
268 277
 	}
@@ -313,6 +322,9 @@  discard block
 block discarded – undo
313 322
 		return file_put_contents($filepath, $this->decode($this->content()));
314 323
 	}
315 324
 
325
+	/**
326
+	 * @param string $content
327
+	 */
316 328
 	public function decode( $content ) {
317 329
 		return base64_decode($content);
318 330
 	}
Please login to merge, or discard this patch.
Braces   +2 added lines, -4 removed lines patch added patch discarded remove patch
@@ -187,8 +187,7 @@  discard block
 block discarded – undo
187 187
 				foreach ( $structure->parts AS $i => $part ) {
188 188
 					if ( 'ALTERNATIVE' == $part->subtype ) {
189 189
 						$parts = array_merge($parts, $this->messageParts($part->parts, $i+1, $IMAPMessagePartClass));
190
-					}
191
-					else {
190
+					} else {
192 191
 						$parts[] = new $IMAPMessagePartClass($this, $part, $i+1);
193 192
 
194 193
 						if ( $part->ifdisposition && 'ATTACHMENT' == $part->disposition ) {
@@ -204,8 +203,7 @@  discard block
 block discarded – undo
204 203
 			foreach ( $parts AS $part ) {
205 204
 				if ( 'PLAIN' == $part->subtype && !$this->plainBody ) {
206 205
 					$this->plainBody = $part;
207
-				}
208
-				else if ( 'HTML' == $part->subtype && !$this->HTMLBody ) {
206
+				} else if ( 'HTML' == $part->subtype && !$this->HTMLBody ) {
209 207
 					$this->HTMLBody = $part;
210 208
 				}
211 209
 			}
Please login to merge, or discard this patch.
test.br-autohelpdesk.php 1 patch
Braces   +1 added lines, -2 removed lines patch added patch discarded remove patch
@@ -100,8 +100,7 @@
 block discarded – undo
100 100
 				$body = imap_fetchbody($mbox, $msgNum, (string)($partNum+1));
101 101
 
102 102
 				return trim($body);
103
-			}
104
-			else if ( 'ALTERNATIVE' == $part->subtype && isset($part->parts) ) {
103
+			} else if ( 'ALTERNATIVE' == $part->subtype && isset($part->parts) ) {
105 104
 				foreach ( $part->parts AS $subPartNum => $subPart ) {
106 105
 					if ( 'PLAIN' == $subPart->subtype ) {
107 106
 						$body = imap_fetchbody($mbox, $msgNum, ($partNum+1).'.'.($subPartNum+1));
Please login to merge, or discard this patch.
test.11nk5.php 1 patch
Braces   +1 added lines, -2 removed lines patch added patch discarded remove patch
@@ -41,8 +41,7 @@
 block discarded – undo
41 41
 					echo "SUBMIT URL: ";
42 42
 					if ( $rsp ) {
43 43
 						var_dump(strlen($rsp));
44
-					}
45
-					else {
44
+					} else {
46 45
 						echo "FAIL\n";
47 46
 						$message->unflag('seen');
48 47
 					}
Please login to merge, or discard this patch.