test paginator
This commit is contained in:
parent
6c4de0fb58
commit
42388f4b63
@ -176,7 +176,6 @@ class Paginator:
|
||||
|
||||
bits = part.split(' ')
|
||||
for bit in bits:
|
||||
print(bit)
|
||||
next_len = length + len(bit) + 1
|
||||
if next_len <= self._max_line_length:
|
||||
out_str += bit + ' '
|
||||
|
||||
@ -71,12 +71,9 @@ class Repl:
|
||||
pass
|
||||
value = format_output(value)
|
||||
pag = Paginator()
|
||||
print(value)
|
||||
pag.add(value)
|
||||
print(ret)
|
||||
pag.add(f'\nReturned: {ret}')
|
||||
for page in pag.pages():
|
||||
print(page)
|
||||
await ctx.send(page)
|
||||
|
||||
@commands.command(hidden=True)
|
||||
|
||||
@ -491,7 +491,7 @@ class Utils:
|
||||
in_time = parsed_tz.localize(in_time)
|
||||
else:
|
||||
em.set_footer(text='Time not given. Using current time.')
|
||||
in_time = parsed_tz.localize(datetime.utcnow())
|
||||
in_time = parsed_tz.localize(datetime.utcnow()) # TODO Fix this
|
||||
except ValueError:
|
||||
raise commands.CommandError(f'For some reason I can\'t parse this time string: \n'
|
||||
f'{orig_time} {time} {parsed_tz}\n'
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user