HasDecodableBody::getDecodedBody()   A
last analyzed

Complexity

Conditions 1
Paths 1

Size

Total Lines 5
Code Lines 2

Duplication

Lines 0
Ratio 0 %

Importance

Changes 2
Bugs 0 Features 0
Metric Value
cc 1
eloc 2
c 2
b 0
f 0
nc 1
nop 1
dl 0
loc 5
rs 10
1
<?php
2
3
namespace Dacastro4\LaravelGmail\Traits;
4
5
trait HasDecodableBody
6
{
7
8
	/**
9
	 * @param $content
10
	 *
11
	 * @return string
12
	 */
13
	public function getDecodedBody($content)
14
	{
15
		$content = str_replace('_', '/', str_replace('-', '+', $content));
16
17
		return base64_decode($content);
18
	}
19
20
}
21