projects
/
mkjsf-moved-to-github.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Fixes NPE in renaming auth response (triggered by SP change)
[mkjsf-moved-to-github.git]
/
src
/
main
/
java
/
com
/
indexdata
/
mkjsf
/
pazpar2
/
commands
/
InitCommand.java
diff --git
a/src/main/java/com/indexdata/mkjsf/pazpar2/commands/InitCommand.java
b/src/main/java/com/indexdata/mkjsf/pazpar2/commands/InitCommand.java
index
ab2e5a1
..
8743874
100644
(file)
--- a/
src/main/java/com/indexdata/mkjsf/pazpar2/commands/InitCommand.java
+++ b/
src/main/java/com/indexdata/mkjsf/pazpar2/commands/InitCommand.java
@@
-6,7
+6,7
@@
import com.indexdata.mkjsf.pazpar2.commands.sp.InitCommandSp;
import com.indexdata.mkjsf.pazpar2.commands.sp.ServiceProxyCommand;
\r
\r
/**
\r
import com.indexdata.mkjsf.pazpar2.commands.sp.ServiceProxyCommand;
\r
\r
/**
\r
- * Represents a Pazpar2 <code>init</code> command, can be accessed by <code>pzreq.init</code>
\r
+ * <b><code>init</code></b> Pazpar2 command, referenced as: <code>pzreq.init</code>
\r
*
\r
* @author Niels Erik
\r
*
\r
*
\r
* @author Niels Erik
\r
*
\r
@@
-74,13
+74,16
@@
public class InitCommand extends Pazpar2Command implements ServiceProxyCommand {
for (String parameterName : parameters.keySet()) {
\r
newCommand.setParameterInState(parameters.get(parameterName).copy());
\r
}
\r
for (String parameterName : parameters.keySet()) {
\r
newCommand.setParameterInState(parameters.get(parameterName).copy());
\r
}
\r
- newCommand.spCommand = this.spCommand;
\r
+ newCommand.spCommand = new InitCommandSp(this);
\r
+ if (spCommand != null && spCommand.getUploadedInitDoc()!=null) {
\r
+ newCommand.spCommand.setUploadedInitDoc(spCommand.getUploadedInitDoc());
\r
+ }
\r
return newCommand;
\r
}
\r
\r
public ServiceProxyCommand getSp() {
\r
if (spCommand==null) {
\r
return newCommand;
\r
}
\r
\r
public ServiceProxyCommand getSp() {
\r
if (spCommand==null) {
\r
- spCommand = new InitCommandSp(this);
\r
+ spCommand = new InitCommandSp(this);
\r
}
\r
return spCommand;
\r
}
\r
}
\r
return spCommand;
\r
}
\r