Skip to content

Commit 7bb7533

Browse files
committed
Finalize
1 parent 5122f4b commit 7bb7533

5 files changed

Lines changed: 7 additions & 8 deletions

File tree

src/file_ref_map.dat

14.1 KB
Binary file not shown.

src/file_ref_map.json

Whitespace-only changes.

tools/FileRefExtractor/BuildMode/Ast.php

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@ public function __construct(
3838
) {
3939
}
4040

41-
public function getOutput(): array
41+
public function getOutput(): string
4242
{
4343
$value = ['_' => 'fileReferenceOrigins', 'ctxs' => $this->output];
4444
Magic::start(false);
@@ -48,8 +48,8 @@ public function getOutput(): array
4848
$TL = new TL((new ReflectionClass(MTProto::class))->newInstanceWithoutConstructor());
4949
$TL->init($s);
5050
$serialized = $TL->serializeObject(['type' => 'FileReferenceOrigins'], $value, '');
51-
$value = $TL->deserialize($serialized, ['type' => '', 'connection' => null, 'encrypted' => true]);
52-
return [$serialized, json_encode($value)];
51+
//$valueDe = $TL->deserialize($serialized, ['type' => '', 'connection' => null, 'encrypted' => true]);
52+
return $serialized;
5353
}
5454

5555
public function addNode(TLContext $ctx, ?array $action = null, ?string $why = null): void

tools/FileRefExtractor/Ops/GetInputChannelOp.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -67,7 +67,7 @@ public function build(TLContext $tl): array
6767
'type' => $this->getType($tl),
6868
'op' => [
6969
'_' => 'getInputChannelOp',
70-
'from' => $this->path->build($tl),
70+
'path' => $this->path->build($tl),
7171
],
7272
];
7373
}

tools/gen_filerefmap.php

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -539,11 +539,10 @@ static function (array $stack) use ($locations, $TL, $tmp, &$validated, $storyMe
539539
$op->build(new TLContext($TL, $output, $constructor, $TL->isConstructor($constructor)));
540540
}
541541
}
542-
$output = $output->getOutput();
542+
$tl = $output->getOutput();
543543

544544
file_put_contents(
545-
__DIR__.'/../src/file_ref_map.json',
546-
json_encode($output)
545+
__DIR__.'/../src/file_ref_map.dat',
546+
$tl
547547
);
548-
549548
echo("OK!\n".PHP_EOL);

0 commit comments

Comments
 (0)