Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Conversation

@motorina0
Copy link
Collaborator

@motorina0 motorina0 commented Jul 9, 2024

Summary

Have a list of extensions which are pre-enabled for the regular users.

Steps:

  • login as admin
  • go to: Server > Server (tab)
  • add the extensions that you want to pre-enable
  • save

image

  • create a new user
  • the selected extensions should be enabled

image

Note: existing users will not get these extensions enabled by default.

@codecov
Copy link

codecov bot commented Jul 9, 2024

Codecov Report

Attention: Patch coverage is 71.42857% with 8 lines in your changes missing coverage. Please review.

Project coverage is 61.33%. Comparing base (fb17611) to head (72fbb72).

Files Patch % Lines
lnbits/core/services.py 70.00% 6 Missing ⚠️
lnbits/core/views/auth_api.py 33.33% 2 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##              dev    #2571      +/-   ##
==========================================
+ Coverage   61.23%   61.33%   +0.10%     
==========================================
  Files          69       69              
  Lines        9921     9924       +3     
==========================================
+ Hits         6075     6087      +12     
+ Misses       3846     3837       -9     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

# --------


async def create_user(
Copy link
Collaborator Author

@motorina0 motorina0 Jul 9, 2024

Choose a reason for hiding this comment

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

Note: create_user and create_account were overlapping. There is now a function in services called create_user_account which encapsulates the logic from here

@arcbtc arcbtc merged commit b256415 into dev Jul 9, 2024
@arcbtc arcbtc deleted the setings_default_user_extensions branch July 9, 2024 12:55
motorina0 added a commit that referenced this pull request Jul 10, 2024
* feat: add `lnbits_user_default_extensions` to `settings`

* refactor: extract `create_user_account` in services

* feat: auto enable user extensions
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants