mirror of
https://github.com/trezor/trezor-firmware.git
synced 2024-11-17 21:22:10 +00:00
fix(python): add default value to protobuf.Field
[no changelog]
This commit is contained in:
parent
6e36f479db
commit
fd1fbc9372
@ -27,7 +27,11 @@ class ${message.name}(protobuf.MessageType):
|
||||
% if message.fields:
|
||||
FIELDS = {
|
||||
% for field in message.fields:
|
||||
% if not field.required:
|
||||
${field.number}: protobuf.Field("${field.name}", "${field.type_name}", repeated=${field.repeated}, required=${field.required}, default=${field.default_value_repr}),
|
||||
% else:
|
||||
${field.number}: protobuf.Field("${field.name}", "${field.type_name}", repeated=${field.repeated}, required=${field.required}),
|
||||
% endif
|
||||
% endfor
|
||||
}
|
||||
|
||||
|
File diff suppressed because it is too large
Load Diff
Loading…
Reference in New Issue
Block a user