Skip to content

Commit

Permalink
Documentation fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
jfirebaugh committed Dec 22, 2015
1 parent 875b859 commit 94353b1
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 6 deletions.
7 changes: 4 additions & 3 deletions js/style/style.js
Original file line number Diff line number Diff line change
Expand Up @@ -317,9 +317,10 @@ Style.prototype = util.inherit(Evented, {
},

/**
* Get a layer by id.
* @param {string} id id of the desired layer
* @returns {Layer} layer
* Return the style layer object with the given `id`.
*
* @param {string} id - id of the desired layer
* @returns {?Object} a layer, if one with the given `id` exists
* @private
*/
getLayer: function(id) {
Expand Down
7 changes: 4 additions & 3 deletions js/ui/map.js
Original file line number Diff line number Diff line change
Expand Up @@ -503,8 +503,9 @@ util.extend(Map.prototype, /** @lends Map.prototype */{
* specified layer via a `ref` property are also removed.
*
* @param {string} id layer id
* @throws {Error} if no layer with the given `id` exists
* @fires layer.remove
* @returns {Map} this
* @returns {Map} `this`
*/
removeLayer: function(id) {
this.style.removeLayer(id);
Expand All @@ -515,8 +516,8 @@ util.extend(Map.prototype, /** @lends Map.prototype */{
/**
* Return the style layer object with the given `id`.
*
* @param {string} id layer ID
* @returns {Object}
* @param {string} id layer id
* @returns {?Object} a layer, if one with the given `id` exists
*/
getLayer: function(id) {
return this.style.getLayer(id);
Expand Down

0 comments on commit 94353b1

Please sign in to comment.