attached sets some sensible defaults for comments and file uploads upon an initial install of project issue.

CommentFileSizeAuthor
#5 new_install_cleanup.patch1012 bytesdww
new_install.patch856 byteshunmonk

Comments

dww’s picture

Status: Needs review » Reviewed & tested by the community

Tested on mysql -- works as advertised and code is fine. My only minor concern was that core already enables comments by default on all node types -- you have to go out of your way to disable them, so that particular variable_set() isn't strictly necessary. But, this defends us against possible future changes in core's default, so what's in here is fine.

hunmonk’s picture

Status: Reviewed & tested by the community » Fixed

committed to HEAD.

dww’s picture

Status: Fixed » Needs work

Argh, that's what I get for being hasty...

That variable set in fact breaks things. ;) devel.module says:

comment_project_issue	s:23:"COMMENT_NODE_READ_WRITE";

tee hee. seems as though the define()'s at the top of comment.module aren't available inside hook_install() like this. :(

dww’s picture

Oh, and while we're at it, we don't need those single quotes around '1' like that for the other 2 settings, either...

dww’s picture

Status: Needs work » Needs review
StatusFileSize
new1012 bytes

Hrm, yeah, I guess this is only a problem when you use an install profile. However, I'm not sure there's much we can do about it in a profile, since we're already including project_issue *after* comment in the list of modules to enable in the d.o testing profile. And, since this variable_set() was only to "future proof" the code, I don't really want to fight install.php and all that for something so trivial (and unnecessary). So, how about this?

hunmonk’s picture

Status: Needs review » Reviewed & tested by the community

code looks good.

dww’s picture

Status: Reviewed & tested by the community » Fixed
Anonymous’s picture

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for two weeks with no activity.