Skip to content

Commit

Permalink
Merge pull request #401 from HackRU/autocheckin
Browse files Browse the repository at this point in the history
check-in-after
  • Loading branch information
shivanmodha authored Nov 7, 2020
2 parents a383437 + 5bab5ae commit b3a0468
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
6 changes: 3 additions & 3 deletions src/components/Dashboard/Dashboard.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -47,11 +47,11 @@ class Dashboard extends Component {
} else {
if (data) {
delete data.auth;
if (defaults.autocheckin && defaults.dayof && !data["check-in"]) {
if (defaults.autocheckin && defaults.dayof && !data["check-in-after"]) {
// Auto checkin the user
this.props.profile.Set(
{
"check-in": true
"check-in-after": true
},
() => {
this.setState({
Expand Down Expand Up @@ -108,7 +108,7 @@ class Dashboard extends Component {
user.how_you_heard_about_hackru = user.how_you_heard_about_hackru || "";
user.reasons = user.reasons || "";
// boolean to show the other stuff
let SHOW_FLAG = defaults.dayof && user["check-in"] && (user["registration_status"] === "confirmed");
let SHOW_FLAG = defaults.dayof && (user["check-in-after"] || user["check-in"]) && (user["registration_status"] === "confirmed");
// let mobile = this.props.isMobile;
let rolesString = "";
Object.keys(user.role).forEach((key) => { if (user.role[key]) { rolesString += `${key}, `; }});
Expand Down
2 changes: 1 addition & 1 deletion src/components/Profile.js
Original file line number Diff line number Diff line change
Expand Up @@ -199,7 +199,7 @@ class Profile {
// Auto checkin the user
this.Set(
{
"check-in": true
"check-in-after": true
},
callback
);
Expand Down

0 comments on commit b3a0468

Please sign in to comment.