Commit 22ede4f2 authored by Brad King's avatar Brad King 💬 Committed by Kitware Robot
Browse files

Merge topic 'membership-optional-expires'

22a0f9d1 gitlab: fix membership addition method
e0d61fdd

 Member: expires_at may be null
Acked-by: Kitware Robot's avatarKitware Robot <kwrobot@kitware.com>
Reviewed-by: Brad King's avatarBrad King <brad.king@kitware.com>
Merge-request: !36
parents 47d475d8 22a0f9d1
......@@ -194,9 +194,9 @@ impl Gitlab {
self._get(&format!("projects/{}/members/{}", project, user))
}
/// Get a team member of a project.
pub fn add_user_to_team(&self, project: ProjectId, user: UserId, access: AccessLevel)
-> GitlabResult<Member> {
/// Add a user to a project.
pub fn add_user_to_project(&self, project: ProjectId, user: UserId, access: AccessLevel)
-> GitlabResult<Member> {
let user_str = format!("{}", user);
let access_str = format!("{}", access);
......
......@@ -542,7 +542,7 @@ pub struct Member {
pub web_url: String,
/// The access level of the user.
pub access_level: u64,
pub expires_at: DateTime<UTC>,
pub expires_at: Option<DateTime<UTC>>,
}
impl From<Member> for UserBasic {
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment