Skip to content

Commit 4fa4c71

Browse files
committed
Fixes NPE since Ginjector is no more required
1 parent 58602d9 commit 4fa4c71

File tree

3 files changed

+3
-6
lines changed

3 files changed

+3
-6
lines changed

Diff for: gwtpplugin/src/com/gwtplatform/plugin/wizard/NewPresenterWizard.java

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/**
2-
* Copyright 2011 IMAGEM Solutions TI santé
2+
* Copyright 2011 IMAGEM Solutions TI sant�
33
*
44
* Licensed under the Apache License, Version 2.0 (the "License");
55
* you may not use this file except in compliance with the License.
@@ -174,7 +174,7 @@ protected boolean finish(IProgressMonitor desiredMonitor) {
174174
}
175175

176176
// Ginjector
177-
if (!page.isWidget()) {
177+
if (!page.isWidget() && !page.getGinjector().isEmpty()) {
178178
monitor.subTask("Provider in Ginjector");
179179
ginjector = new Ginjector(root, page.getGinjector(), sourceWriterFactory);
180180
ginjector.createProvider(presenter.getType());

Diff for: gwtpplugin/src/com/gwtplatform/plugin/wizard/NewPresenterWizardPage.java

+1-4
Original file line numberDiff line numberDiff line change
@@ -977,12 +977,9 @@ public void widgetDefaultSelected(SelectionEvent e) {
977977
protected IStatus ginChanged() {
978978
StatusInfo status = new StatusInfo();
979979

980-
if (ginjector.isEnabled()) {
981-
if (ginjector.getText().isEmpty()) {
980+
if (ginjector.isEnabled() && !ginjector.getText().isEmpty()) {
982981
// from 0.8 The Ginjector and ProviderBundle's are no longer required to be created
983982
// and updated by hand, all that needed to do is point GWTP to the Gin modules.
984-
return status;
985-
}
986983
try {
987984
IType type = getJavaProject().findType(ginjector.getText());
988985
if (type == null || !type.exists()) {

0 commit comments

Comments
 (0)