From c3e203caead2143694678f2f8676495f17fd486d Mon Sep 17 00:00:00 2001 From: Dan Ryan Date: Sun, 3 Dec 2017 19:22:18 -0500 Subject: [PATCH] Undo control flow changes and move comment --- pipenv/utils.py | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) diff --git a/pipenv/utils.py b/pipenv/utils.py index 0efbfc85..c079523a 100644 --- a/pipenv/utils.py +++ b/pipenv/utils.py @@ -950,12 +950,11 @@ def split_section(input_file, section_suffix, test_function): lockfile_sections = ('default', 'develop') if any(section in input_file for section in pipfile_sections): sections = pipfile_sections + elif any(section in input_file for section in lockfile_sections): + sections = lockfile_sections else: - if any(section in input_file for section in lockfile_sections): - sections = lockfile_sections - else: - # return the original file if we can't find any pipfile or lockfile sections - return input_file + # return the original file if we can't find any pipfile or lockfile sections + return input_file for section in sections: split_dict = {}