aboutsummaryrefslogtreecommitdiffstats
path: root/vnfmarket/src/main/webapp/vnfmarket/node_modules/lodash/array/last.js
diff options
context:
space:
mode:
Diffstat (limited to 'vnfmarket/src/main/webapp/vnfmarket/node_modules/lodash/array/last.js')
-rw-r--r--vnfmarket/src/main/webapp/vnfmarket/node_modules/lodash/array/last.js19
1 files changed, 19 insertions, 0 deletions
diff --git a/vnfmarket/src/main/webapp/vnfmarket/node_modules/lodash/array/last.js b/vnfmarket/src/main/webapp/vnfmarket/node_modules/lodash/array/last.js
new file mode 100644
index 00000000..299af314
--- /dev/null
+++ b/vnfmarket/src/main/webapp/vnfmarket/node_modules/lodash/array/last.js
@@ -0,0 +1,19 @@
+/**
+ * Gets the last element of `array`.
+ *
+ * @static
+ * @memberOf _
+ * @category Array
+ * @param {Array} array The array to query.
+ * @returns {*} Returns the last element of `array`.
+ * @example
+ *
+ * _.last([1, 2, 3]);
+ * // => 3
+ */
+function last(array) {
+ var length = array ? array.length : 0;
+ return length ? array[length - 1] : undefined;
+}
+
+module.exports = last;