diff options
| -rw-r--r-- | bin/flycheck-android-kotlin.py | 23 |
1 files changed, 7 insertions, 16 deletions
diff --git a/bin/flycheck-android-kotlin.py b/bin/flycheck-android-kotlin.py index f8167c4..c42f5f4 100644 --- a/bin/flycheck-android-kotlin.py +++ b/bin/flycheck-android-kotlin.py @@ -94,22 +94,13 @@ def run_kotlinc(cp, files, output, args, sourcefile, outdir): command.append('-Xno-optimize') command.append(sourcefile) # Must include all source files or internal access will fail - if outdir: - with tempfile.NamedTemporaryFile(mode='w') as f: - command.append('@' + f.name) - for source in filter_source_files(files): - f.write(source) - f.write('\n') - f.flush() - return subprocess.call(command) - else: - with tempfile.NamedTemporaryFile(mode='w') as f: - command.append('@' + f.name) - for source in filter_source_files(files): - f.write(source) - f.write('\n') - f.flush() - return subprocess.call(command) + with tempfile.NamedTemporaryFile(mode='w') as f: + command.append('@' + f.name) + for source in filter_source_files(files): + f.write(source) + f.write('\n') + f.flush() + return subprocess.call(command) def file_in_list(needle, files): """Find needle in files and if so, return the list without needle. |
