do put+get in one operation

git-svn-id: https://svn.apache.org/repos/asf/lucene/solr/trunk@601106 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
Yonik Seeley 2007-12-04 22:09:41 +00:00
parent 91d9ce1721
commit e706c72b55
1 changed files with 1 additions and 4 deletions

View File

@ -73,7 +73,7 @@ public class ModifiableSolrParams extends SolrParams
* Add the given values to any existing name
*/
public void add( String name, String ... val ) {
String[] old = vals.get( name );
String[] old = vals.put(name, val);
if( old != null ) {
int i =0;
if( val == null || val.length < 1 ) {
@ -95,9 +95,6 @@ public class ModifiableSolrParams extends SolrParams
vals.put( name, both );
}
}
else {
vals.put( name, val );
}
}
/**