<commit_before>package modules.admin.User.actions;

import modules.admin.domain.Contact;
import modules.admin.domain.Contact.ContactType;
import modules.admin.domain.User;
import modules.admin.domain.User.WizardState;

import org.skyve.metadata.controller.ServerSideAction;
import org.skyve.metadata.controller.ServerSideActionResult;
import org.skyve.web.WebContext;

public class New implements ServerSideAction<User> {
	/**
	 * For Serialization.
	 */
	private static final long serialVersionUID = 7776867319664519408L;

	@Override
	public ServerSideActionResult<User> execute(User adminUser, WebContext webContext) throws Exception {
	
		// Clear out old matches
		adminUser.getCandidateContacts().clear();
		
		Contact contact = Contact.newInstance();
		String searchContactName = adminUser.getSearchContactName(); 
		if (searchContactName == null) {
			searchContactName = "<New Person>";
		}
		contact.setName(searchContactName);
		contact.setEmail1(adminUser.getSearchEmail());
		contact.setContactType(ContactType.person);<commit_msg>Remove confusing contact name placeholder value during new user creation.<commit_after>package modules.admin.User.actions;

import org.skyve.metadata.controller.ServerSideAction;
import org.skyve.metadata.controller.ServerSideActionResult;
import org.skyve.web.WebContext;

import modules.admin.domain.Contact;
import modules.admin.domain.Contact.ContactType;
import modules.admin.domain.User;
import modules.admin.domain.User.WizardState;

public class New implements ServerSideAction<User> {

	private static final long serialVersionUID = 7776867319664519408L;

	@Override
	public ServerSideActionResult<User> execute(User adminUser, WebContext webContext) throws Exception {
	
		// Clear out old matches
		adminUser.getCandidateContacts().clear();
		
		Contact contact = Contact.newInstance();
		String searchContactName = adminUser.getSearchContactName(); 
		contact.setName(searchContactName);
		contact.setEmail1(adminUser.getSearchEmail());
		contact.setContactType(ContactType.person);
{'fraction_non_alphanumeric': 0.09430255402750491, 'fraction_numerical': 0.019646365422396856, 'mean_word_length': 6.172535211267606, 'pattern_counts': {'":': 0, '<': 8, '<?xml version=': 0, '>': 8, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '6075959', 'n_tokens_mistral': 610, 'n_tokens_neox': 552, 'n_words': 116}