for testing and deploying your application
for finding and fixing issues
for empowering human code reviews
<?php
namespace Distilleries\Contentful\Models;
/**
* @property string $lon
* @property string $lat
*/
class Location
{
* {@inheritdoc}
protected $fillable = [
'lon',
'lat'
];
* @param array $attributes
* @return void
@return
Adding a @return annotation to a constructor is not recommended, since a constructor does not have a meaningful return value.
Please refer to the PHP core documentation on constructors.
public function __construct(array $attributes = [])
$this->fill($attributes);
}
* Fill the model with an array of attributes.
*
* @return $this
public function fill(array $attributes)
foreach ($attributes as $key => $value) {
if (in_array($key, $this->fillable)) {
$this->{$key} = $value;
return $this;
Adding a
@return
annotation to a constructor is not recommended, since a constructor does not have a meaningful return value.Please refer to the PHP core documentation on constructors.