This repository was archived by the owner on Feb 1, 2019. It is now read-only.
File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -4,6 +4,12 @@ All notable changes to this project will be documented in this file.
44The format is based on [ Keep a Changelog] ( http://keepachangelog.com/ )
55and this project adheres to [ Semantic Versioning] ( http://semver.org/ ) .
66
7+ ## [ 1.2.1] - 2016-11-29
8+
9+ ### Changed
10+
11+ - Fix for event mixin trigger logic.
12+
713## [ 1.2.0] - 2016-11-14
814
915### Added
Original file line number Diff line number Diff line change 11{
22 "name" : " atomic-component" ,
3- "version" : " 1.2.0 " ,
3+ "version" : " 1.2.1s " ,
44 "description" : " Basic Atomic Component" ,
55 "main" : " index.js" ,
66 "scripts" : {
Original file line number Diff line number Diff line change @@ -37,15 +37,17 @@ var Events = {
3737 return this ;
3838 } ,
3939
40- /**
40+ /**
4141 * Function used to trigger events that exist on the event stack.
4242 *
4343 * @param {string } eventName - The name of the event to trigger.
4444 * @returns {object } An instance.
4545 */
4646 trigger : function ( eventName ) {
47- var events = this . events = this . events || { } ;
48- events [ eventName ] = events [ eventName ] || [ ] ;
47+ var events = this . events || { } ;
48+ if ( events . hasOwnProperty ( eventName ) === false ) {
49+ return this ;
50+ }
4951 for ( var i = 0 , len = events [ eventName ] . length ; i < len ; i ++ ) {
5052 this . events [ eventName ] [ i ] . apply ( this , arguments ) ;
5153 }
You can’t perform that action at this time.
0 commit comments