mirror of
https://github.com/wanghongenpin/proxypin.git
synced 2026-05-06 00:06:04 +08:00
Request edit records http request (#253)
This commit is contained in:
@@ -78,6 +78,10 @@ class HttpBodyState extends State<HttpBodyWidget> {
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
if (widget.httpMessage == null) {
|
||||
return const SizedBox();
|
||||
}
|
||||
|
||||
if ((widget.httpMessage?.body == null || widget.httpMessage?.body?.isEmpty == true) &&
|
||||
widget.httpMessage?.messages.isNotEmpty == false) {
|
||||
return const SizedBox();
|
||||
@@ -85,7 +89,7 @@ class HttpBodyState extends State<HttpBodyWidget> {
|
||||
|
||||
var tabs = Tabs.of(widget.httpMessage?.contentType, isJsonText());
|
||||
|
||||
if (tabIndex >= tabs.list.length) tabIndex = tabs.list.length - 1;
|
||||
if (tabIndex > 0 && tabIndex >= tabs.list.length) tabIndex = tabs.list.length - 1;
|
||||
bodyKey.currentState?.changeState(widget.httpMessage, tabs.list[tabIndex]);
|
||||
|
||||
List<Widget> list = [
|
||||
|
||||
Reference in New Issue
Block a user