Browse Source

Use sha hashes instead of primary key

master
Dylan Baker 5 years ago
parent
commit
117cb06ca9
2 changed files with 2 additions and 1 deletions
  1. 1
    1
      src/cli.rs
  2. 1
    0
      src/client.rs

+ 1
- 1
src/cli.rs View File

44
 
44
 
45
     match create_snippet(snippet, &config) {
45
     match create_snippet(snippet, &config) {
46
         Ok(resp) => match resp {
46
         Ok(resp) => match resp {
47
-            ApiResult::IncomingSnippet { id, .. } => println!("{}/snippets/{}", url, id),
47
+            ApiResult::IncomingSnippet { uuid, .. } => println!("{}/snippets/{}", url, uuid),
48
             ApiResult::IncomingError { message } => println!("error: {}", message),
48
             ApiResult::IncomingError { message } => println!("error: {}", message),
49
         },
49
         },
50
         Err(err) => println!("{}", err),
50
         Err(err) => println!("{}", err),

+ 1
- 0
src/client.rs View File

22
         id: i32,
22
         id: i32,
23
         title: String,
23
         title: String,
24
         body: String,
24
         body: String,
25
+        uuid: String,
25
         created_at: NaiveDateTime,
26
         created_at: NaiveDateTime,
26
     },
27
     },
27
     IncomingError {
28
     IncomingError {

Loading…
Cancel
Save