Skip to content

Make Default field private#314

Merged
kbrock merged 1 commit intoactive-hash:masterfrom
kbrock:default_field
Jun 5, 2025
Merged

Make Default field private#314
kbrock merged 1 commit intoactive-hash:masterfrom
kbrock:default_field

Conversation

@kbrock
Copy link
Collaborator

@kbrock kbrock commented Jul 8, 2024

Followup to #312

I noticed that this is public.

We either want to make this private Or we want to to_sym` the field name.

I went with the first, but just say if you would rather make it public and I can add a to_sym instead.

@kbrock kbrock added the bug label Jul 8, 2024
@kbrock kbrock requested a review from flavorjones July 11, 2024 19:19
Copy link
Collaborator

@flavorjones flavorjones left a comment

Choose a reason for hiding this comment

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

LGTM, I think we should make this private, people should be using the field(default:) option.

@kbrock
Copy link
Collaborator Author

kbrock commented Jul 14, 2024

update:

  • sorry. removed first commit which was unrelated

This is now just converting a private field

@flavorjones
Copy link
Collaborator

LGTM!

@kbrock kbrock merged commit 97643bc into active-hash:master Jun 5, 2025
@kbrock kbrock deleted the default_field branch June 5, 2025 19:07
kbrock added a commit to kbrock/active_hash that referenced this pull request Jul 29, 2025
- Add i18n support active-hash#230 @ryu-sato
- Add `column_names` method active-hash#311 @hatsu38
- Support Active Record 7.2 active-hash#317 @ashleyHutton
- Support ruby 3.4 active-hash#328 @flavorjones
- Add `:alias` to `has_many :through` active-hash#329 @alexgriff
- Add Active Record 8.0 active-hash#324 @flavorjones

- Fix Do not suppress load errors#309 @andreynering
- Ensure `field_names` are all strings active-hash#312 @flavorjones
- Hide private `add_default_value` active-hash#314 @kbrock
- Fix `exists?(nil)` active-hash#320 @y-yagi
- Enance Enum support active-hash#321 @hatsu38
- Updated docs active-hash#326 @y-yagi

- Drop Active Record < 6.1. Ruby < 3.0 active-hash#324 @flavorjones
kbrock added a commit to kbrock/active_hash that referenced this pull request Jul 29, 2025
Added
=====

- Add i18n support active-hash#230 @ryu-sato
- Add `column_names` method active-hash#311 @hatsu38
- Support Active Record 7.2 active-hash#317 @ashleyHutton
- Support ruby 3.4 active-hash#328 @flavorjones
- Add `:alias` to `has_many :through` active-hash#329 @alexgriff
- Add Active Record 8.0 active-hash#324 @flavorjones

Fixed
=====

- Fix Do not suppress load errors#309 @andreynering
- Ensure `field_names` are all strings active-hash#312 @flavorjones
- Hide private `add_default_value` active-hash#314 @kbrock
- Fix `exists?(nil)` active-hash#320 @y-yagi
- Enance Enum support active-hash#321 @hatsu38
- Updated docs active-hash#326 @y-yagi

Removed
=======

- Drop Active Record < 6.1. Ruby < 3.0 active-hash#324 @flavorjones
@kbrock kbrock mentioned this pull request Jul 29, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants