sutty-liquid 0.1.0 → 0.1.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/jekyll/filters/sample.rb +11 -8
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 80dcc3abc95fa1284a2fe605cbea560484b2d711351f60175bb3aba0cc85b2c5
|
4
|
+
data.tar.gz: a2d79c43e542447a4acf8146c8f80e49a68cc78582aa6f72314da55a68decdf8
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 7a843c2327f75c56684fd34873c999657b4aafcf2bc48e38b593eb0c571d9dde655109a235c309a949e9dd7b705b968476433b423660179e7bcc3ddb2623c0d4
|
7
|
+
data.tar.gz: 7686d8f2e1317a112a2d86cb479789d2b6316426e6b72eaf035fd105b9f2cc74fa1940f6693fe56184eb3fb5d466b8dea879169568e1361d91c71912ef02ca27
|
@@ -1,14 +1,17 @@
|
|
1
|
+
# frozen_string_literal: true
|
1
2
|
|
2
3
|
module Jekyll
|
3
|
-
module
|
4
|
-
|
5
|
-
|
6
|
-
|
7
|
-
|
8
|
-
|
9
|
-
|
4
|
+
module Filters
|
5
|
+
module Sample
|
6
|
+
# Returns a random item from an Array
|
7
|
+
#
|
8
|
+
# @input [Array]
|
9
|
+
# @return [Any]
|
10
|
+
def sample(input)
|
11
|
+
return unless input.respond_to? :sample
|
10
12
|
|
11
|
-
|
13
|
+
input.sample
|
14
|
+
end
|
12
15
|
end
|
13
16
|
end
|
14
17
|
end
|