Skip to content
Snippets Groups Projects
Verified Commit 75e718f2 authored by Nick Thomas's avatar Nick Thomas
Browse files

Generate HTTP URLs for custom Pages domains when appropriate

parent 2c66b942
No related branches found
No related tags found
No related merge requests found
Loading
Loading
@@ -27,7 +27,7 @@ class PagesDomain < ActiveRecord::Base
def url
return unless domain
 
if certificate
if certificate.present?
"https://#{domain}"
else
"http://#{domain}"
Loading
Loading
---
title: Generate HTTP URLs for custom Pages domains when appropriate
merge_request: 16279
author:
type: fixed
Loading
Loading
@@ -68,7 +68,7 @@ describe PagesDomain do
subject { domain.url }
 
context 'without the certificate' do
let(:domain) { build(:pages_domain) }
let(:domain) { build(:pages_domain, certificate: '') }
 
it { is_expected.to eq('http://my.domain.com') }
end
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment