mirror of
https://github.com/coding-horror/basic-computer-games.git
synced 2025-12-12 07:40:50 -08:00
Fix unmatched quotes error
This commit is contained in:
@@ -32,7 +32,7 @@ def input(prompt)
|
|||||||
next_string.chomp!('"')
|
next_string.chomp!('"')
|
||||||
else
|
else
|
||||||
# No close quote – Vintage Basic crashes in this case
|
# No close quote – Vintage Basic crashes in this case
|
||||||
raise ArgumentError('Unmatched quotes in input')
|
raise 'Unmatched quotes in input'
|
||||||
end
|
end
|
||||||
elsif scanner.exist?(/,/)
|
elsif scanner.exist?(/,/)
|
||||||
next_string = scanner.scan_until(/,/).chomp(',')
|
next_string = scanner.scan_until(/,/).chomp(',')
|
||||||
|
|||||||
Reference in New Issue
Block a user