Skip to content

Commit

Permalink
Fix to output console log
Browse files Browse the repository at this point in the history
Signed-off-by: Kotaro Inoue <[email protected]>
  • Loading branch information
musaprg committed Jul 23, 2023
1 parent fa28fb6 commit f9ad610
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions librarejob/rarejob.go
Original file line number Diff line number Diff line change
Expand Up @@ -209,6 +209,7 @@ func (c *client) Login(ctx context.Context, username, password string) error {

func (c *client) ReserveTutor(ctx context.Context, from time.Time, margin time.Duration) (*Reserve, error) {
defer zap.L().Sync()
defer c.flushConsoleLogs()

// TODO(musaprg): split this function into two

Expand Down Expand Up @@ -301,8 +302,6 @@ func (c *client) ReserveTutor(ctx context.Context, from time.Time, margin time.D
c.saveCurrentScreenshot(rarejobctlTempDir, "reservation_completed.png")
zap.L().Debug("reservation completed")

c.flushConsoleLogs()

return &Reserve{
Name: tutors[0].Name,
StartAt: tutors[0].AvailableSlots[0],
Expand Down

0 comments on commit f9ad610

Please sign in to comment.