Skip to content

Conversation

@paulohenriquesg
Copy link

Use case: the field name is idAdmin.

Before, the generated code was:

...
	const ID_ADMIN = 'idAdmin';
...
	protected $casts = [
		self::IDADMIN => 'int', // <- wrong constant
	];

After, it is:

...
	protected $casts = [
		self::ID_ADMIN => 'int'
	];

Use case: the field name is `idAdmin`.

Before, the generated code was:

```
...
	const ID_ADMIN = 'idAdmin';
...
	protected $casts = [
		self::IDADMIN => 'int', // <- wrong constant
	];
```

After, it is:

```
...
	protected $casts = [
		self::ID_ADMIN => 'int'
	];

```
@paulohenriquesg paulohenriquesg changed the title Fix constante names on casts and fillable Fix constant names on casts and fillable Aug 3, 2023
Copy link

@Rene-Welbers Rene-Welbers left a comment

Choose a reason for hiding this comment

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

had the same issue. this fixed it

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.

2 participants