diff --git a/modules/components/Route.js b/modules/components/Route.js index ec36501774..4a99ce1070 100644 --- a/modules/components/Route.js +++ b/modules/components/Route.js @@ -1,7 +1,6 @@ var React = require('react'); var warning = require('react/lib/warning'); var invariant = require('react/lib/invariant'); -var emptyFunction = require('react/lib/emptyFunction'); var ExecutionEnvironment = require('react/lib/ExecutionEnvironment'); var mergeProperties = require('../helpers/mergeProperties'); var goBack = require('../helpers/goBack'); @@ -445,7 +444,7 @@ function computeHandlerProps(matches, query) { key: null, params: null, query: null, - activeRouteHandler: emptyFunction.thatReturnsNull + activeRouteHandler: returnNull }; var childHandler; @@ -462,7 +461,7 @@ function computeHandlerProps(matches, query) { if (childHandler) { props.activeRouteHandler = childHandler; } else { - props.activeRouteHandler = emptyFunction.thatReturnsNull; + props.activeRouteHandler = returnNull; } childHandler = function (props, addedProps) { @@ -476,6 +475,10 @@ function computeHandlerProps(matches, query) { return props; } +function returnNull() { + return null; +} + function reversedArray(array) { return array.slice(0).reverse(); }