Skip to content

Commit 9ea9189

Browse files
fix: fix type conversion
1 parent 7cb9763 commit 9ea9189

File tree

1 file changed

+3
-6
lines changed
  • list-targets-with-changed-files/src

1 file changed

+3
-6
lines changed

list-targets-with-changed-files/src/run.ts

Lines changed: 3 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -97,7 +97,7 @@ export const run = (input: Input): Result => {
9797
tfmigrates,
9898
);
9999

100-
const moduleCallerMap = input.module_callers;
100+
const moduleCallerMap: Map<string, string[]> = new Map(Object.entries(input.moduleCallers));
101101
const modules = [...moduleCallerMap.keys()];
102102
modules.sort();
103103
modules.reverse();
@@ -203,7 +203,7 @@ type Input = {
203203
moduleFiles: string[];
204204
pr: string;
205205
payload: Payload;
206-
module_callers: Map<string, string[]>;
206+
moduleCallers: any;
207207
};
208208

209209
const listWD = (configFiles: string[]): string[] => {
@@ -330,10 +330,7 @@ export const main = () => {
330330
module1: [caller1, caller2],
331331
}
332332
*/
333-
module_callers: JSON.parse(core.getInput("module_callers") || "{}") as Map<
334-
string,
335-
string[]
336-
>,
333+
moduleCallers: JSON.parse(core.getInput("module_callers") || "{}"),
337334
});
338335

339336
core.info(`result: ${JSON.stringify(result)}`);

0 commit comments

Comments
 (0)