Skip to content

Commit

Permalink
updated linting, moved transaction from service to controller level (…
Browse files Browse the repository at this point in the history
…this should fix a deadlock error)
  • Loading branch information
tim-fabian committed May 1, 2024
1 parent 4090141 commit 3022c9f
Show file tree
Hide file tree
Showing 30 changed files with 289 additions and 253 deletions.
54 changes: 27 additions & 27 deletions .github/workflows/deploy.yml
Original file line number Diff line number Diff line change
@@ -1,32 +1,32 @@
name: Deploy

on:
pull_request:
types: [closed]
branches:
- release
pull_request:
types: [closed]
branches:
- release

jobs:
build:
if: github.event.pull_request.merged
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
with:
# The branch, tag or SHA to checkout. When checking out the repository that
# triggered a workflow, this defaults to the reference or SHA for that event.
# Otherwise, defaults to `master`.
ref: "dev"
- name: npm install
run: |
cd $GITHUB_WORKSPACE
npm i
- name: build package
run: |
cd $GITHUB_WORKSPACE
npm run build
- name: publish to npm
uses: JS-DevTools/npm-publish@v1
with:
token: ${{ secrets.NPM_TOKEN }}
package: ./package.json
build:
if: github.event.pull_request.merged
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
with:
# The branch, tag or SHA to checkout. When checking out the repository that
# triggered a workflow, this defaults to the reference or SHA for that event.
# Otherwise, defaults to `master`.
ref: "dev"
- name: npm install
run: |
cd $GITHUB_WORKSPACE
npm i
- name: build package
run: |
cd $GITHUB_WORKSPACE
npm run build
- name: publish to npm
uses: JS-DevTools/npm-publish@v1
with:
token: ${{ secrets.NPM_TOKEN }}
package: ./package.json
42 changes: 21 additions & 21 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,24 +3,24 @@ name: CI/CD
on: push
# workflow run is made up of one or more jobs that can run sequentially or in parallel
jobs:
test:
# The type of runner that the job will run on
runs-on: ubuntu-latest
steps:
# Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it
- uses: actions/checkout@v3
# runs npm i inside the root directory
- name: npm i root
run: |
cd $GITHUB_WORKSPACE
npm i
# builds the library
- name: build package
run: |
cd $GITHUB_WORKSPACE
npm run build
# runs tests and linting
- name: Test
run: |
cd $GITHUB_WORKSPACE
npm run test
test:
# The type of runner that the job will run on
runs-on: ubuntu-latest
steps:
# Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it
- uses: actions/checkout@v3
# runs npm i inside the root directory
- name: npm i root
run: |
cd $GITHUB_WORKSPACE
npm i
# builds the library
- name: build package
run: |
cd $GITHUB_WORKSPACE
npm run build
# runs tests and linting
- name: Test
run: |
cd $GITHUB_WORKSPACE
npm run test
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -89,7 +89,7 @@ Then you need to call `/2fa/confirm-turn-on` with a 6 digit code generated by eg

Now that two factor authentication is setup the user gets prompted to enter his two factor code when he tries to login.

If you want to enable the feature for other endpoints aswell, you can configure the `@authenticator` decorator accordingly:
If you want to enable the feature for other endpoints aswell, you can configure the `@authenticate` decorator accordingly:

```typescript
// ...
Expand Down

0 comments on commit 3022c9f

Please sign in to comment.