Index: fpdfsdk/src/javascript/app.cpp |
diff --git a/fpdfsdk/src/javascript/app.cpp b/fpdfsdk/src/javascript/app.cpp |
index 80a9b17aa9c38c03af0309d5ae6a2518451531f7..379170f292f613b5b8df737805b4b223ea504034 100644 |
--- a/fpdfsdk/src/javascript/app.cpp |
+++ b/fpdfsdk/src/javascript/app.cpp |
@@ -201,11 +201,12 @@ FX_BOOL app::viewerVersion(IJS_Context* cc, |
CJS_Context* pContext = (CJS_Context*)cc; |
CPDFSDK_Document* pCurDoc = pContext->GetReaderDocument(); |
CPDFXFA_Document* pDoc = pCurDoc->GetDocument(); |
- if (pDoc->GetDocType() == 1 || pDoc->GetDocType() == 2) |
+ if (pDoc->GetDocType() == 1 || pDoc->GetDocType() == 2) { |
vp << JS_NUM_VIEWERVERSION_XFA; |
- else |
- vp << JS_NUM_VIEWERVERSION; |
+ return TRUE; |
+ } |
+ vp << JS_NUM_VIEWERVERSION; |
return TRUE; |
} |