close
Warning:
Can't synchronize with repository "(default)" (Unsupported version control system "svn": No module named svn). Look in the Trac log for more information.
- Timestamp:
-
Aug 26, 2008, 3:48:13 PM (16 years ago)
- Author:
-
cmlenz
- Comment:
-
Add whitelist view def
Legend:
- Unmodified
- Added
- Removed
- Modified
-
v7
|
v8
|
|
123 | 123 | }}} |
124 | 124 | |
| 125 | === `_design/comments` === |
| 126 | |
| 127 | ==== `whitelist` ==== |
| 128 | |
| 129 | ''Map'': |
| 130 | {{{ |
| 131 | #!javascript |
| 132 | function(doc) { |
| 133 | if (doc.type == 'Comment' && doc.published) { |
| 134 | emit(doc.openid, 1); |
| 135 | } |
| 136 | } |
| 137 | }}} |
| 138 | |
| 139 | ''Reduce'': |
| 140 | {{{ |
| 141 | #!javascript |
| 142 | function(keys, values) { |
| 143 | return sum(values); |
| 144 | } |
| 145 | }}} |
| 146 | |
125 | 147 | === `_design/pings` === |
126 | 148 | |