Skip to content

Commit ae1a864

Browse files
committed
fix(play): a file that comes while the package to keep is built does not take the place of the one it is built from (#92)
1 parent 36bb1c9 commit ae1a864

1 file changed

Lines changed: 3 additions & 2 deletions

File tree

‎src/h5p/play/play-page.ts‎

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -258,8 +258,9 @@ function fetching(name: string, received: number, total: number): void {
258258
function take(files: File[]): void {
259259
if (!files.length || !wanted.length) return
260260
// A file that comes late, from a parent still bringing what the person chose themselves
261-
// meanwhile, must not start the activity again under them.
262-
if (whole) return
261+
// meanwhile, must not start the activity again under them, nor take the place of the file
262+
// the package to keep is being built from.
263+
if (whole || packing) return
263264
// Where one file is named, a second choice replaces the first.
264265
if (wanted.length === 1) chosen.clear()
265266
for (const file of files) chosen.set(file.name, file)

0 commit comments

Comments
 (0)