Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
Nicholas Bailey
rust-gitlab
Commits
74a8daf7
Commit
74a8daf7
authored
Oct 10, 2019
by
Ben Boeckel
⛰
Browse files
clippy: use simplified struct initialization
parent
3a55a767
Changes
2
Hide whitespace changes
Inline
Side-by-side
src/gitlab.rs
View file @
74a8daf7
...
...
@@ -161,8 +161,8 @@ impl Gitlab {
let
api
=
Gitlab
{
client
:
Client
::
new
(),
base_url
:
base_url
,
token
:
token
,
base_url
,
token
,
};
// Ensure the API is working.
...
...
@@ -1011,8 +1011,8 @@ impl Gitlab {
self
.post_with_param
(
&
format!
(
"projects/{}/pipeline"
,
project
),
CreatePipelineParams
{
ref_
:
ref_
,
variables
:
variables
,
ref_
,
variables
,
},
)
}
...
...
src/types.rs
View file @
74a8daf7
...
...
@@ -1221,7 +1221,7 @@ impl Milestone {
iid
:
MilestoneInternalId
::
new
(
0
),
project_id
:
Some
(
project_id
),
group_id
:
None
,
title
:
title
,
title
,
description
:
None
,
state
:
MilestoneState
::
Active
,
created_at
:
DateTime
::
from
(
Utc
::
now
()),
...
...
@@ -1325,8 +1325,8 @@ impl Label {
pub
fn
new
(
name
:
String
,
color
:
LabelColor
)
->
Label
{
Label
{
id
:
LabelId
::
new
(
0
),
name
:
name
,
color
:
color
,
name
,
color
,
description
:
None
,
open_issues_count
:
None
,
closed_issues_count
:
None
,
...
...
@@ -1465,8 +1465,8 @@ impl Issue {
Issue
{
id
:
IssueId
::
new
(
0
),
iid
:
IssueInternalId
::
new
(
0
),
project_id
:
project_id
,
title
:
title
,
project_id
,
title
,
description
:
None
,
state
:
IssueState
::
Opened
,
created_at
:
DateTime
::
from
(
Utc
::
now
()),
...
...
@@ -1475,7 +1475,7 @@ impl Issue {
closed_by
:
None
,
labels
:
Vec
::
new
(),
milestone
:
None
,
author
:
author
,
author
,
assignee
:
None
,
assignees
:
None
,
subscribed
:
None
,
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment