Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Expanded email regex and repinned devops-resources to working version #412

Merged
merged 1 commit into from
Dec 8, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion examples/ch7/devops-api/go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ go 1.19

require (
github.com/gin-gonic/gin v1.8.1
github.com/liatrio/devops-bootcamp/examples/ch7/devops-resources v0.0.0-20221129190731-63b117bcfecd
github.com/liatrio/devops-bootcamp/examples/ch7/devops-resources v0.0.0-20230921193819-569bb9d9dbdd
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I would love to know what causes this to change. So we can have some confidence that it is not going to happen again 'randomly'

)

require (
Expand Down
4 changes: 2 additions & 2 deletions examples/ch7/devops-api/go.sum
Original file line number Diff line number Diff line change
Expand Up @@ -32,8 +32,8 @@ github.com/kr/text v0.2.0 h1:5Nx0Ya0ZqY2ygV366QzturHI13Jq95ApcVaJBhpS+AY=
github.com/kr/text v0.2.0/go.mod h1:eLer722TekiGuMkidMxC/pM04lWEeraHUUmBw8l2grE=
github.com/leodido/go-urn v1.2.1 h1:BqpAaACuzVSgi/VLzGZIobT2z4v53pjosyNd9Yv6n/w=
github.com/leodido/go-urn v1.2.1/go.mod h1:zt4jvISO2HfUBqxjfIshjdMTYS56ZS/qv49ictyFfxY=
github.com/liatrio/devops-bootcamp/examples/ch7/devops-resources v0.0.0-20221129190731-63b117bcfecd h1:qrYCoa6c0YfJI2bXBgqstKhIBIe+5Mm3AMolgiYttOU=
github.com/liatrio/devops-bootcamp/examples/ch7/devops-resources v0.0.0-20221129190731-63b117bcfecd/go.mod h1:Wy8YNDvnY+iVDU2soHwZQFTv0NQ1sBoJQVTe44z4wF0=
github.com/liatrio/devops-bootcamp/examples/ch7/devops-resources v0.0.0-20230921193819-569bb9d9dbdd h1:eiG3C02qmeb9b59I0ZRKItggRZ8Yy1YkIHVnY6+A+hA=
github.com/liatrio/devops-bootcamp/examples/ch7/devops-resources v0.0.0-20230921193819-569bb9d9dbdd/go.mod h1:4/jOK0F/KUFEvemqN4XCD4aVXhAMEZ+VDXR1mPB9CFk=
github.com/mattn/go-isatty v0.0.14 h1:yVuAays6BHfxijgZPzw+3Zlu5yQgKGP2/hcQbHb7S9Y=
github.com/mattn/go-isatty v0.0.14/go.mod h1:7GGIvUiUoEMVVmxf/4nioHXj79iQHKdU27kJ6hsGG94=
github.com/modern-go/concurrent v0.0.0-20180228061459-e0a39a4cb421 h1:ZqeYNhU3OHLH3mGKHDcjJRFFRrJa6eAM5H+CtDdOsPc=
Expand Down
4 changes: 2 additions & 2 deletions examples/ch7/devops-api/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ import (
"regexp"

"github.com/gin-gonic/gin"
"github.com/liatrio/devops-bootcamp/examples/ch7/devops-resources"
devops_resource "github.com/liatrio/devops-bootcamp/examples/ch7/devops-resources"
)

// Global maps to access our resources by id key
Expand All @@ -16,7 +16,7 @@ var operations = make([]*devops_resource.Ops, 0)
var developer_operations = make([]*devops_resource.DevOps, 0)

func verifyEmail(email string) bool {
result, _ := regexp.MatchString("^([a-zA-Z]|[0-9])+@[a-z]+\\.[a-z]+(\\.[a-z]+)*$", email)
result, _ := regexp.MatchString("^[\\w._%+\\-\\/\\]+@[\\w.\\-]+\\.[a-z]{2,4}$", email)
return result
}

Expand Down
Loading