From b3d6620f7314497bbd1e6e250dc6690862ffc916 Mon Sep 17 00:00:00 2001 From: Brett Sun Date: Fri, 15 Jan 2016 13:58:15 +0100 Subject: [PATCH] Simplify example in naming conventions for sources --- js/sources/NAMING_CONVENTIONS.md | 10 +++------- 1 file changed, 3 insertions(+), 7 deletions(-) diff --git a/js/sources/NAMING_CONVENTIONS.md b/js/sources/NAMING_CONVENTIONS.md index 81158793..17898ce1 100644 --- a/js/sources/NAMING_CONVENTIONS.md +++ b/js/sources/NAMING_CONVENTIONS.md @@ -22,12 +22,8 @@ refreshApplicationToken we cannot repeat this for a sources' methods as patterns like this would emerge in the stores: ```javascript -onFetchCurrentUser(invalidateCache) { - this.invalidateCache = invalidateCache; - - if(!this.getInstance().isLoading()) { - this.getInstance().fetchCurrentUser(); // does not call a flux "action" but a method in user_source.js - which is confusing - } +onFetchCurrentUser() { + this.getInstance().fetchCurrentUser(); // does not call a flux "action" but a method in user_source.js - which is confusing } ``` @@ -67,4 +63,4 @@ lookupCurrentUser: { UserActions.logoutCurrentUser UserStore.onLogoutCurrentUser UserSource.performLogoutCurrentUser -``` \ No newline at end of file +```