Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP

Loading…

return numeric values as numbers, not strings #16

Closed
wants to merge 1 commit into from

1 participant

@mpenet

No description provided.

@mpenet

I am not sure this is really usefull to clucy (I only use it to read from an index created by another lib, that includes typed numeric values), since it treats every value as strings.

@technomancy technomancy referenced this pull request
Open

Need a new maintainer #23

@mpenet mpenet closed this
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Commits on Mar 20, 2013
  1. @mpenet
This page is out of date. Refresh to see the latest.
Showing with 2 additions and 1 deletion.
  1. +2 −1  src/clucy/core.clj
View
3  src/clucy/core.clj
@@ -128,7 +128,8 @@
(document->map document score (constantly nil)))
([^Document document score highlighter]
(let [m (into {} (for [^Field f (.getFields document)]
- [(keyword (.name f)) (.stringValue f)]))
+ [(keyword (.name f)) (or (.numericValue f)
+ (.stringValue f))]))
fragments (highlighter m) ; so that we can highlight :_content
m (dissoc m :_content)]
(with-meta
Something went wrong with that request. Please try again.