1Password / connect-sdk-python

Python SDK for 1Password Connect
https://developer.1password.com/docs/connect
MIT License
200 stars 30 forks source link

Update example main.py to handle 'n' input #91

Closed williamhpark closed 8 months ago

williamhpark commented 10 months ago

Overview

The example/main.py script currently doesn't properly accept n as an input when prompted with Would you like to delete the newly created item from your vault? (y/n)

Type of change

Bug fix

Related Issue(s)

N/A

How To Test

  1. Run the Python Connect SDK example
  2. When you see Would you like to delete the newly created item from your vault? (y/n), enter n

Current Behavior

Your answer should be either 'y' or 'n'. Would you like to delete the newly created item from your vault? (y/n) is continuously prompted, until y is entered.

New (Fixed) Behavior

The item is not deleted from the vault and the example script terminates. Both uppercase Y/N and lowercase y/n are accepted.