Adapting plugin for custom post type?

The problem was with $this->setup_links(); which used add_action("publish_post", array(&$this, "saving_posts")); instead of add_action("save_post", array(&$this, "saving_posts"));

Apparently publish_post doesn’t work with custom post types.

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)