Hi, On Tue, Aug 8, 2017 at 12:23 AM, Dave Cramer <davecra...@gmail.com> wrote:
I don't think this line in web/pgadmin/browser/server_groups/servers/types.py > does what it should. > > default_path = config.DEFAULT_BINARY_PATHS[st.stype] or "" > > will ever succeed if the key does not exist > > Attached patch should work. > It can be written as: default_path = config.DEFAULT_BINARY_PATHS.get(st.stype, "") Reference link <https://docs.quantifiedcode.com/python-anti-patterns/correctness/not_using_get_to_return_a_default_value_from_a_dictionary.html#best-practice> Thanks for the patch. > Dave Cramer >