Fix logo sourcing, update privacy policy accordingly

This commit is contained in:
Laura Hausmann 2022-02-10 00:19:49 +01:00
parent af02bfd2ff
commit dde18b5aad
Signed by: zotan
GPG key ID: D044E84C5BE01605
2 changed files with 17 additions and 9 deletions

View file

@ -1,5 +1,8 @@
@page @page
@using global::c3stream.DataModels @using global::c3stream.DataModels
@using System.Net.Http
@using System.Net
@using System.IO
@model InfoModel @model InfoModel
@{ @{
ViewData["Title"] = "Info"; ViewData["Title"] = "Info";
@ -51,13 +54,19 @@
}; };
} }
@if (System.IO.File.Exists(logoPath)) { @if (!System.IO.File.Exists(logoPath)) {
<img src="@(c3stream.CacheUrl + $"{conference.Acronym}/logo.png")" alt="Conference logo" style="max-height: 110px; float: right;"/> if (!Directory.Exists(System.IO.Path.Combine(c3stream.CachePath, conference.Acronym))) {
} Directory.CreateDirectory(System.IO.Path.Combine(c3stream.CachePath, conference.Acronym));
else { }
<img src="@conference.LogoUri" alt="Conference logo" style="max-height: 110px; float: right;"/>
using var httpClient = new HttpClient();
await using var stream = httpClient.GetStreamAsync(conference.LogoUri).Result;
await using var fileStream = new FileStream(logoPath, FileMode.CreateNew);
await stream.CopyToAsync(fileStream);
} }
<img src="@(c3stream.CacheUrl + $"{conference.Acronym}/logo.png")" alt="Conference logo" style="max-height: 110px; float: right;"/>
@if (isWatched) { @if (isWatched) {
<h3 style="color: #95cb7a">@title - <i>@speakers</i></h3> <h3 style="color: #95cb7a">@title - <i>@speakers</i></h3>
} }
@ -114,4 +123,4 @@ else {
</p> </p>
Share this talk:<br/> Share this talk:<br/>
<code onclick="copyToClipboard(this)">https://@Request.Host.Value/Info?guid=@Request.Query["guid"]</code> <code onclick="copyToClipboard(this)">https://@Request.Host.Value/Info?guid=@Request.Query["guid"]</code>

View file

@ -5,12 +5,11 @@
} }
<h3>Privacy Policy</h3> <h3>Privacy Policy</h3>
<p style="text-align: justify"> <p style="text-align: justify">
Last update: 2022-02-09 <br/><br/> Last update: 2022-02-10 <br/><br/>
All data saved about you on this website is the watched status of talks you marked in association with your randomly generated bookmark UUID. <br/> All data saved about you on this website is the watched status of talks you marked in association with your randomly generated bookmark UUID. <br/>
No logs are kept, no trackers used. <br/> No logs are kept, no trackers used. <br/>
</p> </p>
<p style="text-align: justify"> <p style="text-align: justify">
Keep in mind that you are forwarded to media.ccc.de when you watch a talk (except when using our mirror). <br/> Keep in mind that you are forwarded to media.ccc.de when you watch a talk (except when using our mirror). <br/>
Furthermore, when you open the info page for a talk, your IP address is shared with media.ccc.de, due to the fetched icon. <br/>
You should therefore reference their privacy policy as well. <br/> You should therefore reference their privacy policy as well. <br/>
</p> </p>