mirror of
https://github.com/LonamiWebs/Telethon.git
synced 2025-08-08 04:52:30 +00:00
Rename generated layer variable to uppercase readonly property
This commit is contained in:
@@ -83,9 +83,10 @@ class TLGenerator:
|
||||
builder.writeln('from . import types, functions')
|
||||
builder.writeln()
|
||||
|
||||
# Create a variable to indicate which layer this is
|
||||
builder.writeln('layer = {} # Current generated layer'.format(
|
||||
TLParser.find_layer(scheme_file)))
|
||||
# Create a read-only property to indicate which layer this is
|
||||
builder.writeln('LAYER = property(fget=lambda: {})'.format(
|
||||
TLParser.find_layer(scheme_file))
|
||||
)
|
||||
builder.writeln()
|
||||
|
||||
# Then create the dictionary containing constructor_id: class
|
||||
|
Reference in New Issue
Block a user