mirror of
https://github.com/greenshot/greenshot
synced 2025-08-14 02:37:03 -07:00
* Fix for bug [#1578], making the Imgur filename configurable and having the current time in the default pattern fixes the information leak.
This commit is contained in:
parent
be515aeac6
commit
85e8a59447
2 changed files with 4 additions and 2 deletions
|
@ -51,7 +51,9 @@ namespace GreenshotImgurPlugin {
|
|||
public bool AddTitle;
|
||||
[IniProperty("AddFilename", Description = "Is the filename passed on to Imgur", DefaultValue = "True")]
|
||||
public bool AddFilename;
|
||||
|
||||
[IniProperty("FilenamePattern", Description = "Filename for the Imgur upload", DefaultValue = "${capturetime:d\"yyyyMMdd-HHmm\"}")]
|
||||
public string FilenamePattern;
|
||||
|
||||
[IniProperty("ImgurUploadHistory", Description="Imgur upload history (ImgurUploadHistory.hash=deleteHash)")]
|
||||
public Dictionary<string, string> ImgurUploadHistory;
|
||||
|
||||
|
|
|
@ -172,7 +172,7 @@ namespace GreenshotImgurPlugin {
|
|||
public bool Upload(ICaptureDetails captureDetails, ISurface surfaceToUpload, out string uploadURL) {
|
||||
SurfaceOutputSettings outputSettings = new SurfaceOutputSettings(config.UploadFormat, config.UploadJpegQuality, config.UploadReduceColors);
|
||||
try {
|
||||
string filename = Path.GetFileName(FilenameHelper.GetFilename(config.UploadFormat, captureDetails));
|
||||
string filename = Path.GetFileName(FilenameHelper.GetFilenameFromPattern(config.FilenamePattern, config.UploadFormat, captureDetails));
|
||||
ImgurInfo imgurInfo = null;
|
||||
|
||||
// Run upload in the background
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue