mirror of
https://github.com/cedricbonhomme/Stegano.git
synced 2025-05-12 17:18:30 +02:00
Default answer is 'Y'.
This commit is contained in:
parent
eea4c4de8e
commit
40c1293df4
2 changed files with 4 additions and 4 deletions
|
@ -44,8 +44,8 @@ def hide(input_image_file, message):
|
|||
|
||||
if img.mode != 'RGB':
|
||||
print('The mode of the image is not RGB. Mode is {}'.format(img.mode))
|
||||
answer = input('Convert the image to RGB (Y / N) ?\n')
|
||||
if answer == 'n':
|
||||
answer = input('Convert the image to RGB ? [Y / n]\n') or 'Y'
|
||||
if answer.lower() == 'n':
|
||||
raise Exception('Not a RGB image.')
|
||||
else:
|
||||
img = img.convert('RGB')
|
||||
|
|
|
@ -45,8 +45,8 @@ def hide(input_image_file, message, generator_function):
|
|||
|
||||
if img.mode != 'RGB':
|
||||
print('The mode of the image is not RGB. Mode is {}'.format(img.mode))
|
||||
answer = input('Convert the image to RGB (Y / N) ?\n')
|
||||
if answer == 'n':
|
||||
answer = input('Convert the image to RGB ? [Y / n]\n') or 'Y'
|
||||
if answer.lower() == 'n':
|
||||
raise Exception('Not a RGB image.')
|
||||
else:
|
||||
img = img.convert('RGB')
|
||||
|
|
Loading…
Add table
Reference in a new issue