| Conditions | 1 |
| Total Lines | 10 |
| Lines | 0 |
| Ratio | 0 % |
| Changes | 0 | ||
| 1 | # frozen_string_literal: true |
||
| 33 | def create_internal(type) |
||
| 34 | entity = type.type.new |
||
| 35 | type.attributes.values.each do |attribute| |
||
| 36 | next if attribute.default.nil? || attribute.virtual |
||
| 37 | segment = Path::Segment.attribute(attribute.name) |
||
| 38 | value = attribute.default |
||
| 39 | type.injector.inject(entity, type, attribute, value, segment) |
||
| 40 | end |
||
| 41 | entity |
||
| 42 | end |
||
| 43 | end |
||
| 49 |