Skip to content

Commit

Permalink
Merge pull request #4 from Th3Shadowbroker/dev/th3shadowbroker
Browse files Browse the repository at this point in the history
Implemented description decoding from base64 to regular text.
  • Loading branch information
Th3Shadowbroker authored Oct 19, 2018
2 parents 598b305 + fb87dfb commit 345ae07
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions Classes/SpigetResource.php
Original file line number Diff line number Diff line change
@@ -75,11 +75,12 @@ public function getFile()

/**
* Get the resource description.
* @param bool $removeHtml Remove the html parts of the description.
* @return string
*/
public function getDescription()
public function getDescription($removeHtml = false )
{
return $this->resource['description'];
return strip_tags( base64_decode($this->resource['description']) );
}

/**
@@ -255,4 +256,4 @@ public static function of($resource)
return new SpigetResource( SpigetAPI::getInstance()->getResource($resource) );
}

}
}

0 comments on commit 345ae07

Please sign in to comment.