Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Conversation

rodrigocalilo
Copy link

The method returns the first 400 characters of the main content.

Copy link
Member

@jgrossi jgrossi left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

thanks man! added a few comments I'd like to discuss first before merging. thanks for the hard work 💪

src/Model/Post.php Outdated Show resolved Hide resolved
src/Model/Post.php Outdated Show resolved Hide resolved
/**
* @var int
*/
protected $characters = 400;
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

make this a constant please

private const SHORT_CONTENT_CHAR_LIMIT = 400;

/**
* @return string
*/
public function getShortContentAttribute()
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

get you please add a test case in PostTest class to support this?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants

Morty Proxy This is a proxified and sanitized view of the page, visit original site.