Day 18

July 26, 2017 16:03 UTC Team berlin diamonds (Discourse) [2017]Subscribe to this teams's activities


  • Learnt about memoization and really enjoyed it :)
  • Extracted the @session instance variable from the constructor of the drive_synchronizer to create a memoized method of it. @session stores the (expensive) external call to google drive of our plugin. Now the call it's only made once and just its cached value will be passed around when the method is called.
  • Deleted the session argument in add_to_folder(session, file) method. session it’s a method itself now and we can call it directly within add_to_folder(), it will return the cached result of @session from the memoized method.
  • Deleted the @number_of_backups = SiteSetting.discourse_backups_quantity from the constructor in drive_synchronizer as we don't need it anymore, it uploads just one backup at a time.
  • Changed the name of the SiteSetting to be specific to the google plugin.

- pulled Jens changes
- looked again into the oauth-api of google drive and made a new branch with that version
- fixed some typos in the blogpost for the teams app
- created a new repo for a bsaic sync plugin
- fixed the typos in the specs and got the tests run green
- merged dev into master branch, to keep the master updated


You must be logged in to add a comment.