feklee / rotogamesq

ROTOGAMEsq — https://sq.rotogame.com

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Hiscore entries not trimmed

feklee opened this issue · comments

This is to avoid duplicate entries that only differ in blanks at the beginning or end.

Annotated screen shot

Done.

Steps:

  • Add trim functionality:
    • client code (so that duplicates are not displayed even before they are removed on the server)
    • server code where hiscore is stored (just to be on the safe side, to prevent people from tricking the system by modifying server requests)
  • Bump version number in “package.json”.
  • Test by playing the same board twice:
    • What happens after entering the same name twice? Only best entry shown.
    • What happens after entering the same name but with different white space at the end? If better, then hiscore is updated, with trimmed name.
    • What happens after entering the same name but with different white space at the beginning? If better, then hiscore is updated, with trimmed name.
  • Tag in Git: v1.19.1
  • Remove duplicates only differing by trimmable white space from existing hiscores tables of boards apple, xmastree:2013-12-11:2013-12-31.