Forum: Typo Ticket #1210 - content state model flawed

Announcement (2017-05-07): is now read-only since I unfortunately do not have the time to support and maintain the forum any more. Please see and for other Rails- und Ruby-related community platforms.
Benjamin Jackson (Guest)
on 2008-03-20 15:58
(Received via mailing list)
Hi all,
Just wanted to email the list as my ticket has not been addressed and
finding more holes in the state model... just looked at the
publication_pending state, and found this:

    def change_published_state(content, published)
      content[:published] = published

      if published && content.published_at <=
        content.state = JustPublished.instance

    def set_published_at(content, new_time)
      content[:published_at] = new_time
      Trigger.remove(content, :trigger_method => 'publish!')
      if new_time.nil?
        content.state = Draft.instance
      elsif new_time <=
        content.state = JustPublished.instance

Unless I'm mistaken, these are called when published and pubished_at are
in the model, right?

In the metaweblog service, the new post and edit post functions set
published and published_at respectively as:

    article.published   = publish      = username
    article.published_at = struct['dateCreated'].to_time.getlocal rescue

    article.published   = publish      = username
    article.published_at  = struct['dateCreated'].to_time.getlocal

So in other words, as a client of the API I have to know that unless I
dateCreated to the future when creating a post, and then never set it at
when editing a post, my post will always be marked for publication even
though I'm explicitly sending published=false.

Please let me know if I'm off here, but I'd love to see this addressed
as my
ticket has been stale for 2-3 weeks. Thanks,

8fe0f48dca9c0121318b67097eb0fcf1?d=identicon&s=25 Lo Po (hashpipe)
on 2008-03-20 16:11
(Received via mailing list)
Yes, this has been a problem with Typo-5.0.2. Even if you set your post
not published, still it will be showing up on ur blog. In the admin
interface, the post will show as not-published, but it will be published
your blog.

On Thu, Mar 20, 2008 at 8:17 PM, Benjamin Jackson <>

>       end
>     end
> though I'm explicitly sending published=false.

Benjamin Jackson (Guest)
on 2008-03-28 05:41
(Received via mailing list)
I hate to be a PITA, but IMHO this is a very severe issue which should
be addressed (especially as the ticket has a working, tested patch).
The fact that this ticket has sat for a month in trac with no response
has me a little bit worried about the future of typo.

Hopefully this will be resolved soon. Thanks,

This topic is locked and can not be replied to.