Skip to content

Commit f36df5f

Browse files
committed
remove unused arg
1 parent 98fa3c0 commit f36df5f

File tree

2 files changed

+5
-6
lines changed
  • packages/svelte/src/compiler/phases/3-transform/client

2 files changed

+5
-6
lines changed

packages/svelte/src/compiler/phases/3-transform/client/transform-template/index.js

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -47,12 +47,11 @@ function build_locations(locations) {
4747

4848
/**
4949
* @param {ComponentClientTransformState} state
50-
* @param {ComponentContext} context
5150
* @param {Namespace} namespace
5251
* @param {Identifier} template_name
5352
* @param {number} [flags]
5453
*/
55-
export function transform_template(state, context, namespace, template_name, flags) {
54+
export function transform_template(state, namespace, template_name, flags) {
5655
const expression =
5756
state.options.templatingMode === 'functional'
5857
? template_to_functions(state.template.nodes)
@@ -68,10 +67,10 @@ export function transform_template(state, context, namespace, template_name, fla
6867
call = b.call(
6968
'$.add_locations',
7069
call,
71-
b.member(b.id(context.state.analysis.name), '$.FILENAME', true),
70+
b.member(b.id(state.analysis.name), '$.FILENAME', true),
7271
build_locations(state.locations)
7372
);
7473
}
7574

76-
context.state.hoisted.push(b.var(template_name, call));
75+
state.hoisted.push(b.var(template_name, call));
7776
}

packages/svelte/src/compiler/phases/3-transform/client/visitors/Fragment.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -96,7 +96,7 @@ export function Fragment(node, context) {
9696

9797
let flags = state.template.needs_import_node ? TEMPLATE_USE_IMPORT_NODE : undefined;
9898

99-
transform_template(state, context, namespace, template_name, flags);
99+
transform_template(state, namespace, template_name, flags);
100100

101101
body.push(b.var(id, b.call(template_name)));
102102
close = b.stmt(b.call('$.append', b.id('$$anchor'), id));
@@ -144,7 +144,7 @@ export function Fragment(node, context) {
144144
// special case — we can use `$.comment` instead of creating a unique template
145145
body.push(b.var(id, b.call('$.comment')));
146146
} else {
147-
transform_template(state, context, namespace, template_name, flags);
147+
transform_template(state, namespace, template_name, flags);
148148

149149
body.push(b.var(id, b.call(template_name)));
150150
}

0 commit comments

Comments
 (0)