mirror of
https://github.com/ProtonMail/proton-bridge.git
synced 2025-12-17 23:56:56 +00:00
GODT-175: Add option to attach logs for bug reports
This commit is contained in:
@ -19,6 +19,8 @@
|
||||
|
||||
package qt
|
||||
|
||||
import "github.com/therecipe/qt/core"
|
||||
|
||||
func (f *FrontendQt) setVersion() {
|
||||
f.qml.SetVersion(f.programVersion)
|
||||
}
|
||||
@ -41,5 +43,21 @@ func (f *FrontendQt) setCurrentEmailClient() {
|
||||
}
|
||||
|
||||
func (f *FrontendQt) reportBug(description, address, emailClient string, includeLogs bool) {
|
||||
//TODO
|
||||
defer f.qml.ReportBugFinished()
|
||||
|
||||
if err := f.bridge.ReportBug(
|
||||
core.QSysInfo_ProductType(),
|
||||
core.QSysInfo_PrettyProductName(),
|
||||
description,
|
||||
"Unknown account",
|
||||
address,
|
||||
emailClient,
|
||||
includeLogs,
|
||||
); err != nil {
|
||||
f.log.WithError(err).Error("Failed to report bug")
|
||||
f.qml.BugReportSendError()
|
||||
return
|
||||
}
|
||||
|
||||
f.qml.BugReportSendSuccess()
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user