Skip to content

Commit

Permalink
Merge branch 'master' of github.com:lichess-org/lila
Browse files Browse the repository at this point in the history
* 'master' of github.com:lichess-org/lila:
  scalafmt
  finish switching to `Relay.Sync.period`
  Mod usertable: show absolute time of the mark
  • Loading branch information
ornicar committed Apr 23, 2023
2 parents d32f7f4 + 0604923 commit d6a3d26
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 9 deletions.
4 changes: 2 additions & 2 deletions app/views/user/mod.scala
Original file line number Diff line number Diff line change
Expand Up @@ -558,8 +558,8 @@ object mod:
private val clean: Frag = iconTag("")
private val reportban = iconTag("")
private val notesText = iconTag("")
private def markTd(nb: Int, content: => Frag, date: Option[Instant] = None) =
if (nb > 0) td(cls := "i", dataSort := nb, title := date.map(momentFromNowServerText(_, false)))(content)
private def markTd(nb: Int, content: => Frag, date: Option[Instant] = None)(using ctx: Context) =
if (nb > 0) td(cls := "i", dataSort := nb, title := date.map(d => showInstantUTC(d)))(content)
else td

def otherUsers(mod: Holder, u: User, data: UserLogins.TableData[UserWithModlog], appeals: List[Appeal])(
Expand Down
10 changes: 5 additions & 5 deletions modules/push/src/main/WebSubscriptionApi.scala
Original file line number Diff line number Diff line change
Expand Up @@ -15,11 +15,11 @@ final class WebSubscriptionApi(coll: Coll)(using Executor):
.one(
$id(sessionId),
$doc(
"userId" -> user.id,
"endpoint" -> subscription.endpoint,
"auth" -> subscription.auth,
"p256dh" -> subscription.p256dh,
"seenAt" -> nowInstant
"userId" -> user.id,
"endpoint" -> subscription.endpoint,
"auth" -> subscription.auth,
"p256dh" -> subscription.p256dh,
"seenAt" -> nowInstant
),
upsert = true
)
Expand Down
4 changes: 2 additions & 2 deletions modules/relay/src/main/RelayRoundForm.scala
Original file line number Diff line number Diff line change
Expand Up @@ -125,7 +125,7 @@ object RelayRoundForm:
},
until = none,
nextAt = none,
delay = period ifTrue Granter(_.Relay)(user),
period = period ifTrue Granter(_.Relay)(user),
log = SyncLog.empty
)

Expand Down Expand Up @@ -154,5 +154,5 @@ object RelayRoundForm:
},
syncUrlRound = relay.sync.upstream.flatMap(_.asUrl).flatMap(_.withRound.round),
startsAt = relay.startsAt,
period = relay.sync.delay
period = relay.sync.period
)

0 comments on commit d6a3d26

Please sign in to comment.