AspNetCore.Docs/aspnet/whitepapers/mvc3-release-notes/samples/sample17.cs

8 lines
204 B
C#

public class UsersController {
public bool UserNameAvailable(string username) {
if(MyRepository.UserNameExists(username)) {
return "false";
}
return "true";
}
}