mirror of
https://github.com/bisq-network/bisq.git
synced 2025-01-19 05:44:05 +01:00
Add check for protocol version at dispute close window
This commit is contained in:
parent
5fc085ed43
commit
4cc2ee4f63
@ -21,6 +21,7 @@ import com.google.common.io.ByteStreams;
|
|||||||
import de.jensd.fx.fontawesome.AwesomeDude;
|
import de.jensd.fx.fontawesome.AwesomeDude;
|
||||||
import de.jensd.fx.fontawesome.AwesomeIcon;
|
import de.jensd.fx.fontawesome.AwesomeIcon;
|
||||||
import io.bitsquare.alert.PrivateNotificationManager;
|
import io.bitsquare.alert.PrivateNotificationManager;
|
||||||
|
import io.bitsquare.app.Version;
|
||||||
import io.bitsquare.arbitration.Dispute;
|
import io.bitsquare.arbitration.Dispute;
|
||||||
import io.bitsquare.arbitration.DisputeManager;
|
import io.bitsquare.arbitration.DisputeManager;
|
||||||
import io.bitsquare.arbitration.messages.DisputeCommunicationMessage;
|
import io.bitsquare.arbitration.messages.DisputeCommunicationMessage;
|
||||||
@ -415,8 +416,17 @@ public class TraderDisputeView extends ActivatableView<VBox, Void> {
|
|||||||
}
|
}
|
||||||
|
|
||||||
private void onCloseDispute(Dispute dispute) {
|
private void onCloseDispute(Dispute dispute) {
|
||||||
disputeSummaryWindow.onFinalizeDispute(() -> messagesAnchorPane.getChildren().remove(messagesInputBox))
|
long protocolVersion = dispute.getContract().offer.getProtocolVersion();
|
||||||
.show(dispute);
|
if (protocolVersion == Version.TRADE_PROTOCOL_VERSION) {
|
||||||
|
disputeSummaryWindow.onFinalizeDispute(() -> messagesAnchorPane.getChildren().remove(messagesInputBox))
|
||||||
|
.show(dispute);
|
||||||
|
} else {
|
||||||
|
new Popup<>()
|
||||||
|
.warning("The offer in that dispute has been created with an older version of Bitsquare.\n" +
|
||||||
|
"You cannot close that dispute with your version of the application.\n\n" +
|
||||||
|
"Please use an older version with protocol version " + protocolVersion)
|
||||||
|
.show();
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
private void onRequestUpload() {
|
private void onRequestUpload() {
|
||||||
|
Loading…
Reference in New Issue
Block a user