Hi @benjaminrau,
I think the if (close) {window.close()} must after the parent if, otherwise the filepicker doesn't close after clicking a thumbnail when using a flexforms file field.

Tank you for the bugfix.