Skip to content

Commit

Permalink
Don't require http:// on hostname for cli
Browse files Browse the repository at this point in the history
  • Loading branch information
dholms committed Apr 12, 2022
1 parent 36f7520 commit 74d0439
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 1 deletion.
2 changes: 2 additions & 0 deletions cli/src/commands/setup/init.ts
Original file line number Diff line number Diff line change
Expand Up @@ -54,6 +54,8 @@ export default cmd({

console.log('Generating repo...')

const serverCleaned = server.replace('http://', '').replace('https://', '')

await config.writeCfg(REPO_PATH, username, server)
const client = await loadDelegate(REPO_PATH)

Expand Down
2 changes: 1 addition & 1 deletion cli/src/lib/client.ts
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ export const loadDelegate = async (
): Promise<MicroblogDelegator> => {
const { account, keypair, ucanStore } = await config.loadCfg(repoPath)
return new MicroblogDelegator(
account.server,
'http://' + account.server,
keypair.did(),
keypair,
ucanStore,
Expand Down

0 comments on commit 74d0439

Please sign in to comment.