I might be wrong, but it looks to me like this entire `if/elsif/else` could be replaced with a one line `published?`