stapix

Yet another static page generator for photo galleries

Commit
08cd30a927fb15e4dc79121c6de3bce1e779aa91
Parent
ed67e6128e2b404034fa973cd94966d8393bf75a
Author
Pablo <pablo-escobar@riseup.net>
Date

Changed the formating of Creative Commons licenses

Diffstat

1 file changed, 7 insertions, 7 deletions

Status File Name N° Changes Insertions Deletions
Modified src/picture.rs 14 7 7
diff --git a/src/picture.rs b/src/picture.rs
@@ -381,21 +381,21 @@ impl Display for LicenseType {
         match self.0 {
             CreativeCommons::CC0 => write!(f, "CC0"),
             CreativeCommons::CCBY { version, non_commercial, share_alike } => {
-                write!(f, "CC-BY-")?;
+                write!(f, "CC-BY")?;
                 if non_commercial {
-                    write!(f, "NC-")?;
+                    write!(f, "-NC")?;
                 }
                 if share_alike {
-                    write!(f, "SA-")?;
+                    write!(f, "-SA")?;
                 }
-                write!(f, "{}", version)
+                write!(f, " {version}")
             },
             CreativeCommons::CCBYND { version, non_commercial } => {
-                write!(f, "CC-BY-")?;
+                write!(f, "CC-BY")?;
                 if non_commercial {
-                    write!(f, "NC-")?;
+                    write!(f, "-NC")?;
                 }
-                write!(f, "ND-{}", version)
+                write!(f, "-ND {version}")
             }
         }
     }