X-Git-Url: https://git.pterodactylus.net/?a=blobdiff_plain;f=src%2Fnet%2Fpterodactylus%2Fjsite%2Fcore%2FProject.java;h=9ddada5243f140df5fb774a6578c4270f41205c9;hb=62d8078eff84dd476c3cf7c6b95b47d1438a1360;hp=8bc45dd06703c90d9875a63232053af0bb63abb2;hpb=164c7174571672ca255b918a56c8db9336e31d19;p=jSite2.git diff --git a/src/net/pterodactylus/jsite/core/Project.java b/src/net/pterodactylus/jsite/core/Project.java index 8bc45dd..9ddada5 100644 --- a/src/net/pterodactylus/jsite/core/Project.java +++ b/src/net/pterodactylus/jsite/core/Project.java @@ -127,7 +127,11 @@ public class Project extends AbstractBean { * The internal ID */ void setId(String id) { - this.id = id; + if (id == null) { + this.id = Hex.toHex(IdGenerator.generateId()); + } else { + this.id = id; + } } /**